We are planning an event-driven GUI where the frontend sends events to the backend where all state is maintained. These events pass through an undo/redo stack where they are stored. Ideally, the payload of these events is typed such that we can verify the integrity of the payloads from TypeScript as well (using serde-generate or something similar)
Here, we need to:
Define some kind of global "app state" object. This object should be "addressable" using labels/paths to ensure the events can reference the objects which they modify.
Define an "event payload" type, and an event struct that can be used to apply this payload to the app state.
We are planning an event-driven GUI where the frontend sends events to the backend where all state is maintained. These events pass through an undo/redo stack where they are stored. Ideally, the payload of these events is typed such that we can verify the integrity of the payloads from TypeScript as well (using serde-generate or something similar)
Here, we need to: