github statelyai/xstate xstate@4.18.0

latest releases: @xstate/vue@4.0.0, @xstate/store@2.6.1, @xstate/svelte@4.0.0...
3 years ago

Minor Changes

  • d0939ec6 #2046 Thanks @SimeonC! - Allow machines to communicate with the inspector even in production builds.

  • e37fffef #2079 Thanks @davidkpiano! - There is now support for "combinatorial machines" (state machines that only have one state):

    const testMachine = createMachine({
      context: { value: 42 },
      on: {
        INC: {
          actions: assign({ value: ctx => ctx.value + 1 })
        }
      }
    });

    These machines omit the initial and state properties, as the entire machine is treated as a single state.

Patch Changes

  • 6a9247d4 #2102 Thanks @VanTanev! - Provide a convenience type for getting the Interpreter type based on the StateMachine type by transferring all generic parameters onto it. It can be used like this: InterpreterFrom<typeof machine>

Don't miss a new xstate release

NewReleases is sending notifications on new releases.