1.3 KiB
1.3 KiB
WRNexusJS v0.6.0 R5 store type regression fix
R4 accidentally restored an older @wrnexus/store type surface while changing the syntax package import boundary.
Corrected
- Shared, client, and server store state now use separate generic types.
StoreCombinedState<S, CS, SS>is used by computed values, actions, persistence, and lifecycle hooks.- Store action inference defaults to callable
StoreFunctionvalues instead ofnever. createClientStateandcreateServerStateno longer have to overlap with shared state.- The internal initialization promise is named
whenReady, allowing application state to usereadysafely. - Generated browser stores also expose
whenReadyrather than reservingready. validate:0.6now guards all of these signatures to prevent regression.
Focused validation
packages/store/test/store.test.tspasses strict TypeScript checking with a localbun:testtype shim.- Runtime probe passes client/server action selection, computed values, client-only state, server-state serialization exclusion, and a boolean state field named
ready. - VS Code tests: 28 passed.
- VS Code validation: all checks passed.
- Repository v0.6 validator: 14 passed, 0 failed; only the expected local Bun availability warning remains in the packaging environment.