For anyone having TypeScript issues with this in XState 4.29+ (where there are new schema and tsTypes attributes on the machine, see xstate.js.org/docs/guides/typescri...), ActorRefFrom no longer seems to work but you can use InterpreterFrom in its place
type GlobalStateContextType = {
authService: InterpreterFrom<typeof authMachine>;
};
For anyone having TypeScript issues with this in XState 4.29+ (where there are new
schema
andtsTypes
attributes on the machine, see xstate.js.org/docs/guides/typescri...),ActorRefFrom
no longer seems to work but you can useInterpreterFrom
in its placeLooks like it's fixed now:
github.com/statelyai/xstate/commit...