Minor Changes
-
#5530
0502c04Thanks @davidkpiano! - Exposestore.schemasso integrations can read the store's context, event, and emitted event schemas at runtime.const store = createStore({ schemas: { context: z.object({ count: z.number() }), events: { inc: z.object({ by: z.number() }) } }, context: { count: 0 }, on: { inc: (context, event) => ({ count: context.count + event.by }) } }); store.schemas?.events?.inc;