Skip to content

Share context between machines? #135

@trafnar

Description

@trafnar

Is it possible to share context between machines? The parallel states section of comparison with xstate suggests modeling parallel states as separate machines, but I have parallel machines that share a single context. Is there a recommendation for doing that?

The situation I have is a video timeline where you can move the playhead back and forth, and there are ranges of time on the timeline which can be manipulated (moved, deleted etc). Those manipulations are modeled by one machine, and I have another machine for adding new ranges, (because that can be done at any time), however the new ranges are added at the current playhead position, which is stored in the context of the first machine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions