Description
The entry function never fires on the initial machine state.
Reproduction
test.js:
import { createMachine, interpret } from '@xstate/fsm';
const beaconMachine = createMachine({
initial: 'uninitialized',
states: {
uninitialized: {
entry: function () {
console.log('I never run :( ');
}
}
}
});
const beaconService = interpret(beaconMachine).start();
I run node -r esm test.js and see no console output
@mreinstein I've prepared a PR to fix this https://github.com/davidkpiano/xstate/pull/827
@Andarist can we ship a new npm release for this?
@mreinstein done
Most helpful comment
@mreinstein I've prepared a PR to fix this https://github.com/davidkpiano/xstate/pull/827