@xmachines/docs 1.0.0-beta.25 → 1.0.0-beta.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/api/@xmachines/play/classes/PlayError.md +10 -4
- package/api/@xmachines/play/type-aliases/PlayEvent.md +2 -2
- package/api/@xmachines/play-actor/README.md +4 -0
- package/api/@xmachines/play-actor/classes/AbstractActor.md +49 -92
- package/api/@xmachines/play-actor/functions/typedSpec.md +57 -0
- package/api/@xmachines/play-actor/interfaces/PlaySpec.md +9 -18
- package/api/@xmachines/play-actor/interfaces/Routable.md +5 -21
- package/api/@xmachines/play-actor/interfaces/ViewMetadata.md +6 -6
- package/api/@xmachines/play-actor/interfaces/Viewable.md +5 -6
- package/api/@xmachines/play-dom/classes/PlayRenderer.md +4 -4
- package/api/@xmachines/play-dom/functions/connectRenderer.md +1 -1
- package/api/@xmachines/play-dom/functions/renderSpec.md +1 -1
- package/api/@xmachines/play-dom/interfaces/ConnectRendererOptions.md +7 -7
- package/api/@xmachines/play-dom/interfaces/DomRenderContext.md +7 -7
- package/api/@xmachines/play-dom/interfaces/PlayDomOptions.md +3 -3
- package/api/@xmachines/play-dom/type-aliases/DomComponentRenderer.md +1 -1
- package/api/@xmachines/play-dom/type-aliases/DomRegistry.md +1 -1
- package/api/@xmachines/play-dom-router/README.md +10 -0
- package/api/@xmachines/play-dom-router/functions/connectRouter.md +18 -46
- package/api/@xmachines/play-dom-router/functions/createBrowserHistory.md +1 -1
- package/api/@xmachines/play-dom-router/functions/createRouteMap.md +38 -0
- package/api/@xmachines/play-dom-router/functions/createRouter.md +1 -1
- package/api/@xmachines/play-dom-router/interfaces/BrowserHistory.md +16 -16
- package/api/@xmachines/play-dom-router/interfaces/BrowserWindow.md +16 -16
- package/api/@xmachines/play-dom-router/interfaces/ConnectRouterOptions.md +6 -6
- package/api/@xmachines/play-dom-router/interfaces/PlayRouteEvent.md +119 -0
- package/api/@xmachines/play-dom-router/interfaces/RouteMap.md +114 -0
- package/api/@xmachines/play-dom-router/interfaces/RouteMapLike.md +50 -0
- package/api/@xmachines/play-dom-router/interfaces/RouteMapping.md +27 -0
- package/api/@xmachines/play-dom-router/interfaces/RouterBridge.md +104 -0
- package/api/@xmachines/play-dom-router/interfaces/VanillaRouter.md +6 -6
- package/api/@xmachines/play-dom-router/type-aliases/RoutableActor.md +9 -0
- package/api/@xmachines/play-react/README.md +4 -4
- package/api/@xmachines/play-react/classes/PlayErrorBoundary.md +31 -5
- package/api/@xmachines/play-react/functions/defineRegistry.md +2 -0
- package/api/@xmachines/play-react/functions/useActor.md +1 -1
- package/api/@xmachines/play-react/functions/useBoundProp.md +2 -0
- package/api/@xmachines/play-react/functions/useSignalEffect.md +1 -1
- package/api/@xmachines/play-react/functions/useStateBinding.md +2 -0
- package/api/@xmachines/play-react/interfaces/ComponentContext.md +2 -0
- package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryProps.md +4 -4
- package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryState.md +3 -3
- package/api/@xmachines/play-react/interfaces/PlayRendererProps.md +7 -7
- package/api/@xmachines/play-react/type-aliases/ComponentFn.md +2 -0
- package/api/@xmachines/play-react/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-react/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-react-router/README.md +5 -1
- package/api/@xmachines/play-react-router/classes/ReactRouterBridge.md +102 -25
- package/api/@xmachines/play-react-router/classes/RouteMap.md +17 -33
- package/api/@xmachines/play-react-router/functions/PlayRouterProvider.md +8 -1
- package/api/@xmachines/play-react-router/functions/createRouteMapFromTree.md +21 -11
- package/api/@xmachines/play-react-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-react-router/interfaces/PlayRouterProviderProps.md +7 -7
- package/api/@xmachines/play-react-router/interfaces/RouteMapping.md +18 -8
- package/api/@xmachines/play-react-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-router/README.md +42 -5
- package/api/@xmachines/play-router/classes/BaseRouteMap.md +12 -19
- package/api/@xmachines/play-router/classes/RouterBridgeBase.md +100 -25
- package/api/@xmachines/play-router/functions/buildPlayRouteEvent.md +1 -1
- package/api/@xmachines/play-router/functions/buildRouteTree.md +1 -1
- package/api/@xmachines/play-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-router/functions/createRouteMapFromMachine.md +38 -0
- package/api/@xmachines/play-router/functions/createRouteMapFromTree.md +45 -0
- package/api/@xmachines/play-router/functions/detectDuplicateRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/extractMachineRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/extractQuery.md +1 -1
- package/api/@xmachines/play-router/functions/extractRouteParams.md +46 -0
- package/api/@xmachines/play-router/functions/findRouteById.md +1 -1
- package/api/@xmachines/play-router/functions/findRouteByPath.md +1 -1
- package/api/@xmachines/play-router/functions/getNavigableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/getRoutableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/getTransitionReachableRoutes.md +1 -1
- package/api/@xmachines/play-router/functions/isRouteReachable.md +1 -1
- package/api/@xmachines/play-router/functions/machineToGraph.md +1 -1
- package/api/@xmachines/play-router/functions/routeExists.md +1 -1
- package/api/@xmachines/play-router/functions/sanitizePathname.md +1 -1
- package/api/@xmachines/play-router/functions/validateRouteFormat.md +1 -1
- package/api/@xmachines/play-router/functions/validateStateExists.md +1 -1
- package/api/@xmachines/play-router/interfaces/BuildPlayRouteEventOptions.md +4 -4
- package/api/@xmachines/play-router/interfaces/LocationLike.md +27 -0
- package/api/@xmachines/play-router/interfaces/MachineEdgeData.md +3 -3
- package/api/@xmachines/play-router/interfaces/MachineNodeData.md +5 -5
- package/api/@xmachines/play-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-router/interfaces/RouteInfo.md +8 -8
- package/api/@xmachines/play-router/interfaces/RouteMap.md +4 -4
- package/api/@xmachines/play-router/interfaces/{BaseRouteMapping.md → RouteMapping.md} +5 -5
- package/api/@xmachines/play-router/interfaces/RouteMatch.md +5 -5
- package/api/@xmachines/play-router/interfaces/RouteNode.md +12 -12
- package/api/@xmachines/play-router/interfaces/RouteObject.md +2 -2
- package/api/@xmachines/play-router/interfaces/RouteTree.md +5 -5
- package/api/@xmachines/play-router/interfaces/RouteWatcherHandle.md +3 -3
- package/api/@xmachines/play-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-router/interfaces/WindowLike.md +65 -0
- package/api/@xmachines/play-router/type-aliases/MachineGraph.md +1 -1
- package/api/@xmachines/play-router/type-aliases/RouteMetadata.md +1 -1
- package/api/@xmachines/play-signals/functions/watchSignal.md +1 -1
- package/api/@xmachines/play-signals/interfaces/ComputedOptions.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalComputed.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalOptions.md +2 -2
- package/api/@xmachines/play-signals/interfaces/SignalState.md +3 -3
- package/api/@xmachines/play-signals/interfaces/SignalWatcher.md +4 -4
- package/api/@xmachines/play-signals/namespaces/Signal/classes/Computed.md +6 -0
- package/api/@xmachines/play-signals/namespaces/Signal/classes/State.md +8 -0
- package/api/@xmachines/play-signals/namespaces/Signal/interfaces/Options.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/classes/Watcher.md +10 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/currentComputed.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/hasSinks.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/hasSources.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/introspectSinks.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/introspectSources.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/functions/untrack.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/variables/unwatched.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/namespaces/subtle/variables/watched.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isComputed.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isState.md +2 -0
- package/api/@xmachines/play-signals/namespaces/Signal/variables/isWatcher.md +2 -0
- package/api/@xmachines/play-signals/type-aliases/WatcherNotify.md +1 -1
- package/api/@xmachines/play-solid/README.md +4 -4
- package/api/@xmachines/play-solid/functions/defineRegistry.md +2 -0
- package/api/@xmachines/play-solid/functions/useActor.md +1 -1
- package/api/@xmachines/play-solid/functions/useStateBinding.md +2 -0
- package/api/@xmachines/play-solid/interfaces/ComponentContext.md +2 -0
- package/api/@xmachines/play-solid/interfaces/PlayRendererProps.md +7 -7
- package/api/@xmachines/play-solid/type-aliases/ComponentFn.md +2 -0
- package/api/@xmachines/play-solid/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-solid/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-solid-router/README.md +2 -2
- package/api/@xmachines/play-solid-router/classes/RouteMap.md +13 -26
- package/api/@xmachines/play-solid-router/classes/SolidRouterBridge.md +121 -46
- package/api/@xmachines/play-solid-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-solid-router/functions/createRouteMap.md +15 -9
- package/api/@xmachines/play-solid-router/interfaces/AbstractActor.md +47 -92
- package/api/@xmachines/play-solid-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-solid-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-solid-router/interfaces/RouteMapping.md +19 -6
- package/api/@xmachines/play-solid-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-solid-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-solid-router/type-aliases/SolidRouterHooks.md +21 -18
- package/api/@xmachines/play-svelte/README.md +28 -0
- package/api/@xmachines/play-svelte/functions/defineRegistry.md +2 -0
- package/api/@xmachines/play-svelte/interfaces/BaseComponentProps.md +2 -0
- package/api/@xmachines/play-svelte/interfaces/ComponentContext.md +2 -0
- package/api/@xmachines/play-svelte/interfaces/PlayRendererProps.md +9 -9
- package/api/@xmachines/play-svelte/type-aliases/ComponentFn.md +2 -0
- package/api/@xmachines/play-svelte/type-aliases/PlayRenderer.md +2 -0
- package/api/@xmachines/play-svelte/variables/PlayRenderer.md +2 -0
- package/api/@xmachines/play-svelte-spa-router/README.md +1 -0
- package/api/@xmachines/play-svelte-spa-router/classes/RouteMap.md +13 -26
- package/api/@xmachines/play-svelte-spa-router/functions/connectRouter.md +14 -1
- package/api/@xmachines/play-svelte-spa-router/functions/createRouteMap.md +23 -4
- package/api/@xmachines/play-svelte-spa-router/interfaces/ConnectRouterOptions.md +6 -5
- package/api/@xmachines/play-svelte-spa-router/interfaces/PlayRouteEvent.md +10 -10
- package/api/@xmachines/play-svelte-spa-router/interfaces/RouteMapping.md +20 -5
- package/api/@xmachines/play-svelte-spa-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-svelte-spa-router/interfaces/WindowLike.md +65 -0
- package/api/@xmachines/play-svelte-spa-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-sveltekit-router/README.md +2 -1
- package/api/@xmachines/play-sveltekit-router/classes/RouteMap.md +46 -24
- package/api/@xmachines/play-sveltekit-router/functions/connectRouter.md +14 -1
- package/api/@xmachines/play-sveltekit-router/functions/createRouteMap.md +23 -4
- package/api/@xmachines/play-sveltekit-router/interfaces/ConnectRouterOptions.md +6 -5
- package/api/@xmachines/play-sveltekit-router/interfaces/LocationLike.md +27 -0
- package/api/@xmachines/play-sveltekit-router/interfaces/PlayRouteEvent.md +10 -10
- package/api/@xmachines/play-sveltekit-router/interfaces/RouteMapping.md +20 -5
- package/api/@xmachines/play-sveltekit-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-sveltekit-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/README.md +5 -3
- package/api/@xmachines/play-tanstack-react-router/classes/RouteMap.md +17 -33
- package/api/@xmachines/play-tanstack-react-router/classes/TanStackReactRouterBridge.md +93 -25
- package/api/@xmachines/play-tanstack-react-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/functions/createRouteMapFromTree.md +21 -11
- package/api/@xmachines/play-tanstack-react-router/functions/extractMachineRoutes.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouteMapping.md +18 -8
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouteNavigateEvent.md +3 -3
- package/api/@xmachines/play-tanstack-react-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterInstance.md +1 -1
- package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterLike.md +6 -26
- package/api/@xmachines/play-tanstack-solid-router/README.md +8 -8
- package/api/@xmachines/play-tanstack-solid-router/classes/RouteMap.md +13 -26
- package/api/@xmachines/play-tanstack-solid-router/classes/SolidRouterBridge.md +101 -36
- package/api/@xmachines/play-tanstack-solid-router/functions/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/functions/createRouteMap.md +15 -9
- package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouterProviderProps.md +5 -5
- package/api/@xmachines/play-tanstack-solid-router/interfaces/RouteMapping.md +13 -9
- package/api/@xmachines/play-tanstack-solid-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterInstance.md +1 -1
- package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterLike.md +23 -24
- package/api/@xmachines/play-vue/README.md +4 -4
- package/api/@xmachines/play-vue/functions/defineRegistry.md +1 -1
- package/api/@xmachines/play-vue/functions/useActor.md +1 -1
- package/api/@xmachines/play-vue/functions/useStateBinding.md +2 -0
- package/api/@xmachines/play-vue/interfaces/ComponentContext.md +2 -0
- package/api/@xmachines/play-vue/interfaces/PlayRendererProps.md +5 -5
- package/api/@xmachines/play-vue/type-aliases/ComponentEntry.md +1 -1
- package/api/@xmachines/play-vue/type-aliases/ComponentFn.md +2 -0
- package/api/@xmachines/play-vue/type-aliases/ComponentsMap.md +1 -1
- package/api/@xmachines/play-vue/type-aliases/DefineRegistryOptions.md +2 -2
- package/api/@xmachines/play-vue/type-aliases/PlayActor.md +1 -1
- package/api/@xmachines/play-vue/variables/PlayRenderer.md +1 -1
- package/api/@xmachines/play-vue-router/README.md +2 -2
- package/api/@xmachines/play-vue-router/classes/RouteMap.md +18 -108
- package/api/@xmachines/play-vue-router/classes/VueBaseRouteMap.md +44 -104
- package/api/@xmachines/play-vue-router/classes/VueRouterBridge.md +127 -62
- package/api/@xmachines/play-vue-router/functions/createRouteMap.md +1 -1
- package/api/@xmachines/play-vue-router/interfaces/PlayRouteEvent.md +8 -8
- package/api/@xmachines/play-vue-router/interfaces/RouteMapping.md +19 -7
- package/api/@xmachines/play-vue-router/interfaces/RouterBridge.md +3 -3
- package/api/@xmachines/play-vue-router/type-aliases/RoutableActor.md +1 -1
- package/api/@xmachines/play-vue-router/variables/PlayRouterProvider.md +1 -1
- package/api/@xmachines/play-xstate/README.md +15 -15
- package/api/@xmachines/play-xstate/classes/PlayerActor.md +46 -30
- package/api/@xmachines/play-xstate/functions/buildRouteUrl.md +20 -15
- package/api/@xmachines/play-xstate/functions/composeGuards.md +1 -1
- package/api/@xmachines/play-xstate/functions/composeGuardsOr.md +1 -1
- package/api/@xmachines/play-xstate/functions/contextFieldMatches.md +1 -1
- package/api/@xmachines/play-xstate/functions/definePlayer.md +1 -1
- package/api/@xmachines/play-xstate/functions/deriveRoute.md +1 -1
- package/api/@xmachines/play-xstate/functions/eventMatches.md +1 -1
- package/api/@xmachines/play-xstate/functions/formatPlayRouteTransitions.md +2 -2
- package/api/@xmachines/play-xstate/functions/hasContext.md +1 -1
- package/api/@xmachines/play-xstate/functions/isAbsoluteRoute.md +1 -1
- package/api/@xmachines/play-xstate/functions/negateGuard.md +1 -1
- package/api/@xmachines/play-xstate/interfaces/PlayerConfig.md +3 -3
- package/api/@xmachines/play-xstate/interfaces/PlayerFactoryResumeOptions.md +2 -2
- package/api/@xmachines/play-xstate/interfaces/PlayerOptions.md +6 -6
- package/api/@xmachines/play-xstate/interfaces/RouteContext.md +14 -12
- package/api/@xmachines/play-xstate/type-aliases/ComposedGuard.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/Guard.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/GuardArray.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/PlayerFactory.md +1 -1
- package/api/@xmachines/play-xstate/type-aliases/RouteMachineConfig.md +4 -4
- package/api/@xmachines/play-xstate/type-aliases/RouteStateNode.md +4 -4
- package/api/@xmachines/shared/functions/defineXmVitestConfig.md +2 -2
- package/api/@xmachines/shared/functions/xmAliases.md +1 -1
- package/api/README.md +4 -4
- package/api/llms.txt +3 -3
- package/examples/README.md +5 -0
- package/examples/routing-patterns.md +6 -4
- package/package.json +2 -2
- package/api/@xmachines/play-tanstack-react-router/functions/extractParams.md +0 -38
- package/api/@xmachines/play-tanstack-react-router/functions/extractQueryParams.md +0 -33
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
type GuardArray<TContext, TEvent> = Guard<TContext, TEvent>[] | string[];
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [packages/play-xstate/src/guards/types.ts:23](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.
|
|
9
|
+
Defined in: [packages/play-xstate/src/guards/types.ts:23](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/guards/types.ts#L23)
|
|
10
10
|
|
|
11
11
|
Array of guard predicates or guard names
|
|
12
12
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
type PlayerFactory<TMachine> = (input?, options?) => PlayerActor<TMachine>;
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [packages/play-xstate/src/types.ts:57](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.
|
|
9
|
+
Defined in: [packages/play-xstate/src/types.ts:57](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/types.ts#L57)
|
|
10
10
|
|
|
11
11
|
Factory function returned by definePlayer()
|
|
12
12
|
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
type RouteMachineConfig = object;
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
9
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:48](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L48)
|
|
10
10
|
|
|
11
11
|
Minimal structural constraint for machine configs accepted by
|
|
12
12
|
`formatPlayRouteTransitions`.
|
|
@@ -32,7 +32,7 @@ through the transform, so the return value remains directly usable by
|
|
|
32
32
|
optional context?: unknown;
|
|
33
33
|
```
|
|
34
34
|
|
|
35
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
35
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:49](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L49)
|
|
36
36
|
|
|
37
37
|
---
|
|
38
38
|
|
|
@@ -42,7 +42,7 @@ Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:5
|
|
|
42
42
|
optional on?: Record<string, unknown>;
|
|
43
43
|
```
|
|
44
44
|
|
|
45
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
45
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:51](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L51)
|
|
46
46
|
|
|
47
47
|
---
|
|
48
48
|
|
|
@@ -52,4 +52,4 @@ Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:5
|
|
|
52
52
|
optional states?: Record<string, unknown>;
|
|
53
53
|
```
|
|
54
54
|
|
|
55
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
55
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:50](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L50)
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
type RouteStateNode = object;
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
9
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:13](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L13)
|
|
10
10
|
|
|
11
11
|
Minimal structural shape of a single XState state node as read by
|
|
12
12
|
`formatPlayRouteTransitions` when crawling the machine config.
|
|
@@ -29,7 +29,7 @@ the index signature.
|
|
|
29
29
|
optional id?: string;
|
|
30
30
|
```
|
|
31
31
|
|
|
32
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
32
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:15](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L15)
|
|
33
33
|
|
|
34
34
|
Optional explicit state ID (e.g. `"home"`, `"settings"`). Used as the `#id` target in `play.route` events.
|
|
35
35
|
|
|
@@ -41,7 +41,7 @@ Optional explicit state ID (e.g. `"home"`, `"settings"`). Used as the `#id` targ
|
|
|
41
41
|
optional meta?: object;
|
|
42
42
|
```
|
|
43
43
|
|
|
44
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
44
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:17](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L17)
|
|
45
45
|
|
|
46
46
|
State metadata — `meta.route` marks the state as routable.
|
|
47
47
|
|
|
@@ -61,6 +61,6 @@ URL path template (e.g. `"/profile/:username"`, `"/settings/:section?"`).
|
|
|
61
61
|
optional states?: Record<string, RouteStateNode>;
|
|
62
62
|
```
|
|
63
63
|
|
|
64
|
-
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:
|
|
64
|
+
Defined in: [packages/play-xstate/src/routing/format-play-route-transitions.ts:22](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/play-xstate/src/routing/format-play-route-transitions.ts#L22)
|
|
65
65
|
|
|
66
66
|
Nested child states, recursively crawled for additional route declarations.
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
function defineXmVitestConfig(importMetaUrl, overrides): object;
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [src/index.ts:10](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.
|
|
9
|
+
Defined in: [src/index.ts:10](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/shared/src/index.ts#L10)
|
|
10
10
|
|
|
11
11
|
Create a Vitest config with XMachines workspace defaults.
|
|
12
12
|
|
|
@@ -26,4 +26,4 @@ render it under `@xmachines/shared` instead of nested module pages.
|
|
|
26
26
|
|
|
27
27
|
| Name | Type | Defined in |
|
|
28
28
|
| ------ | ----- | ---------------------------------------------------------------------------------------------------------------------------- |
|
|
29
|
-
| `test` | `any` | [config/vitest.ts:82](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.
|
|
29
|
+
| `test` | `any` | [config/vitest.ts:82](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/shared/config/vitest.ts#L82) |
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
function xmAliases(importMetaUrl): Record<string, string>;
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Defined in: [src/index.ts:20](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.
|
|
9
|
+
Defined in: [src/index.ts:20](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.26/packages/shared/src/index.ts#L20)
|
|
10
10
|
|
|
11
11
|
Build Vite/Vitest alias entries for all `@xmachines/*` workspace packages.
|
|
12
12
|
|
package/api/README.md
CHANGED
|
@@ -7,8 +7,8 @@ Generated API documentation for the XMachines JavaScript/TypeScript packages.
|
|
|
7
7
|
- For actor contracts, start with [@xmachines/play-actor](@xmachines/play-actor/README.md).
|
|
8
8
|
- For player creation from XState machines, start with [@xmachines/play-xstate](@xmachines/play-xstate/README.md).
|
|
9
9
|
- For route extraction and shared URL synchronization logic, start with [@xmachines/play-router](@xmachines/play-router/README.md).
|
|
10
|
-
- For rendering, choose one of [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), or [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
11
|
-
- For framework router integration, choose the matching adapter package such as [@xmachines/play-react-router](@xmachines/play-react-router/README.md)
|
|
10
|
+
- For rendering, choose one of [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), [@xmachines/play-svelte](@xmachines/play-svelte/README.md), or [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
11
|
+
- For framework router integration, choose the matching adapter package such as [@xmachines/play-react-router](@xmachines/play-react-router/README.md), [@xmachines/play-vue-router](@xmachines/play-vue-router/README.md), [@xmachines/play-sveltekit-router](@xmachines/play-sveltekit-router/README.md), or [@xmachines/play-svelte-spa-router](@xmachines/play-svelte-spa-router/README.md).
|
|
12
12
|
|
|
13
13
|
## Key Concepts
|
|
14
14
|
|
|
@@ -19,8 +19,8 @@ Generated API documentation for the XMachines JavaScript/TypeScript packages.
|
|
|
19
19
|
## Package Roles
|
|
20
20
|
|
|
21
21
|
- `Core runtime`: [@xmachines/play](@xmachines/play/README.md), [@xmachines/play-actor](@xmachines/play-actor/README.md), [@xmachines/play-signals](@xmachines/play-signals/README.md), [@xmachines/play-router](@xmachines/play-router/README.md), and [@xmachines/play-xstate](@xmachines/play-xstate/README.md)
|
|
22
|
-
- `Rendering`: [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), and [@xmachines/play-vue](@xmachines/play-vue/README.md)
|
|
23
|
-
- `Router adapters`: [@xmachines/play-react-router](@xmachines/play-react-router/README.md), [@xmachines/play-tanstack-react-router](@xmachines/play-tanstack-react-router/README.md), [@xmachines/play-solid-router](@xmachines/play-solid-router/README.md),
|
|
22
|
+
- `Rendering`: [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), [@xmachines/play-svelte](@xmachines/play-svelte/README.md), and [@xmachines/play-vue](@xmachines/play-vue/README.md)
|
|
23
|
+
- `Router adapters`: [@xmachines/play-react-router](@xmachines/play-react-router/README.md), [@xmachines/play-tanstack-react-router](@xmachines/play-tanstack-react-router/README.md), [@xmachines/play-solid-router](@xmachines/play-solid-router/README.md), [@xmachines/play-tanstack-solid-router](@xmachines/play-tanstack-solid-router/README.md), [@xmachines/play-vue-router](@xmachines/play-vue-router/README.md), [@xmachines/play-sveltekit-router](@xmachines/play-sveltekit-router/README.md), and [@xmachines/play-svelte-spa-router](@xmachines/play-svelte-spa-router/README.md)
|
|
24
24
|
- `Shared tooling`: [@xmachines/shared](@xmachines/shared/README.md)
|
|
25
25
|
|
|
26
26
|
## Notes
|
package/api/llms.txt
CHANGED
|
@@ -12,14 +12,14 @@
|
|
|
12
12
|
- Understanding actor contracts: read [@xmachines/play-actor](@xmachines/play-actor/README.md) for [Viewable](@xmachines/play-actor/interfaces/Viewable.md) and [Routable](@xmachines/play-actor/interfaces/Routable.md).
|
|
13
13
|
- [Viewable](@xmachines/play-actor/interfaces/Viewable.md) is the rendering contract: actors expose `currentView` plus a component catalog so rendering packages can resolve UI without owning application state.
|
|
14
14
|
- [Routable](@xmachines/play-actor/interfaces/Routable.md) is the routing contract: actors expose `currentRoute` plus route-oriented event handling, while adapters translate browser or router changes into actor events.
|
|
15
|
-
- Rendering actor-driven UI: use [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), or [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
15
|
+
- Rendering actor-driven UI: use [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), [@xmachines/play-svelte](@xmachines/play-svelte/README.md), or [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
16
16
|
- Synchronizing URLs with actor state: use [@xmachines/play-router](@xmachines/play-router/README.md) plus a framework-specific router adapter.
|
|
17
17
|
|
|
18
18
|
## Package Roles
|
|
19
19
|
|
|
20
20
|
- `Core runtime`: [@xmachines/play](@xmachines/play/README.md), [@xmachines/play-actor](@xmachines/play-actor/README.md), [@xmachines/play-signals](@xmachines/play-signals/README.md), [@xmachines/play-router](@xmachines/play-router/README.md), and [@xmachines/play-xstate](@xmachines/play-xstate/README.md). Catalog and component registry are provided by `@json-render/core` and the framework rendering packages.
|
|
21
|
-
- `Rendering`: [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), and [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
22
|
-
- `Router adapters`: [@xmachines/play-react-router](@xmachines/play-react-router/README.md), [@xmachines/play-tanstack-react-router](@xmachines/play-tanstack-react-router/README.md), [@xmachines/play-solid-router](@xmachines/play-solid-router/README.md), [@xmachines/play-tanstack-solid-router](@xmachines/play-tanstack-solid-router/README.md),
|
|
21
|
+
- `Rendering`: [@xmachines/play-react](@xmachines/play-react/README.md), [@xmachines/play-solid](@xmachines/play-solid/README.md), [@xmachines/play-svelte](@xmachines/play-svelte/README.md), and [@xmachines/play-vue](@xmachines/play-vue/README.md).
|
|
22
|
+
- `Router adapters`: [@xmachines/play-react-router](@xmachines/play-react-router/README.md), [@xmachines/play-tanstack-react-router](@xmachines/play-tanstack-react-router/README.md), [@xmachines/play-solid-router](@xmachines/play-solid-router/README.md), [@xmachines/play-tanstack-solid-router](@xmachines/play-tanstack-solid-router/README.md), [@xmachines/play-vue-router](@xmachines/play-vue-router/README.md), [@xmachines/play-sveltekit-router](@xmachines/play-sveltekit-router/README.md), and [@xmachines/play-svelte-spa-router](@xmachines/play-svelte-spa-router/README.md), all built on top of [Routable](@xmachines/play-actor/interfaces/Routable.md) actors and shared route metadata.
|
|
23
23
|
- `Shared tooling`: [@xmachines/shared](@xmachines/shared/README.md) for shared config and workspace-level support files.
|
|
24
24
|
|
|
25
25
|
## API
|
package/examples/README.md
CHANGED
|
@@ -40,6 +40,11 @@ Complete working applications demonstrating actor-authoritative routing, shared
|
|
|
40
40
|
|
|
41
41
|
- **[Vue Router Demo](../api/@xmachines/play-vue-router-demo/README.md)** - Vue Composition API integration with the same shared auth and routing patterns
|
|
42
42
|
|
|
43
|
+
### Svelte Integrations
|
|
44
|
+
|
|
45
|
+
- **[SvelteKit Router Demo](../api/@xmachines/play-sveltekit-router-demo/README.md)** - SvelteKit-style routing with `afterNavigate`/`goto` and Svelte 5 runes
|
|
46
|
+
- **[Svelte SPA Router Demo](../api/@xmachines/play-svelte-spa-router-demo/README.md)** - Hash-based SPA routing using `svelte-spa-router` with the same actor-authoritative flow
|
|
47
|
+
|
|
43
48
|
### Solid Integrations
|
|
44
49
|
|
|
45
50
|
- **[Solid Router Demo](../api/@xmachines/play-solid-router-demo/README.md)** - Solid fine-grained reactivity with `@solidjs/router` and provider-based routing
|
|
@@ -62,7 +62,8 @@ const authMachine = setup({
|
|
|
62
62
|
context: {} as {
|
|
63
63
|
isAuthenticated: boolean;
|
|
64
64
|
userId: string;
|
|
65
|
-
|
|
65
|
+
params: Record<string, string>;
|
|
66
|
+
query: Record<string, string>;
|
|
66
67
|
},
|
|
67
68
|
events: {} as
|
|
68
69
|
| { type: "play.route"; to: string; params?: Record<string, string> }
|
|
@@ -73,7 +74,8 @@ const authMachine = setup({
|
|
|
73
74
|
context: {
|
|
74
75
|
isAuthenticated: false,
|
|
75
76
|
userId: "",
|
|
76
|
-
|
|
77
|
+
params: {},
|
|
78
|
+
query: {},
|
|
77
79
|
},
|
|
78
80
|
states: {
|
|
79
81
|
login: {
|
|
@@ -99,7 +101,7 @@ const authMachine = setup({
|
|
|
99
101
|
route: "/profile/:userId",
|
|
100
102
|
view: {
|
|
101
103
|
component: "ProfileView",
|
|
102
|
-
userId: (ctx) => ctx.
|
|
104
|
+
userId: (ctx) => ctx.params.userId || ctx.userId,
|
|
103
105
|
},
|
|
104
106
|
},
|
|
105
107
|
always: [
|
|
@@ -113,7 +115,7 @@ const authMachine = setup({
|
|
|
113
115
|
"play.route": {
|
|
114
116
|
actions: ({ context, event }) => {
|
|
115
117
|
if (event.params?.userId) {
|
|
116
|
-
context.
|
|
118
|
+
context.params = { userId: event.params.userId };
|
|
117
119
|
}
|
|
118
120
|
},
|
|
119
121
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xmachines/docs",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.26",
|
|
4
4
|
"description": "Documentation for XMachines",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"documentation",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"typedoc": "typedoc"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@xmachines/shared": "1.0.0-beta.
|
|
51
|
+
"@xmachines/shared": "1.0.0-beta.26",
|
|
52
52
|
"oxfmt": "^0.43.0",
|
|
53
53
|
"oxlint": "^1.57.0",
|
|
54
54
|
"typedoc": "^0.28.18",
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
[Documentation](../../../README.md) / [@xmachines/play-tanstack-react-router](../README.md) / extractParams
|
|
2
|
-
|
|
3
|
-
# Function: extractParams()
|
|
4
|
-
|
|
5
|
-
```ts
|
|
6
|
-
function extractParams(pathname, pattern): Record<string, string>;
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
Defined in: [play-tanstack-react-router/src/extract-params.ts:29](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.25/packages/play-tanstack-react-router/src/extract-params.ts#L29)
|
|
10
|
-
|
|
11
|
-
Extract route parameters from URL path based on route pattern using URLPattern API
|
|
12
|
-
|
|
13
|
-
## Parameters
|
|
14
|
-
|
|
15
|
-
| Parameter | Type | Description |
|
|
16
|
-
| ---------- | -------- | ---------------------------------------------------- |
|
|
17
|
-
| `pathname` | `string` | Actual URL path (e.g., "/profile/123") |
|
|
18
|
-
| `pattern` | `string` | Route pattern with params (e.g., "/profile/:userId") |
|
|
19
|
-
|
|
20
|
-
## Returns
|
|
21
|
-
|
|
22
|
-
`Record`\<`string`, `string`\>
|
|
23
|
-
|
|
24
|
-
Object with extracted parameters
|
|
25
|
-
|
|
26
|
-
## Example
|
|
27
|
-
|
|
28
|
-
```typescript
|
|
29
|
-
extractParams("/profile/123", "/profile/:userId");
|
|
30
|
-
// Returns: { userId: "123" }
|
|
31
|
-
|
|
32
|
-
extractParams("/api/123", "/api/:id(\\d+)");
|
|
33
|
-
// Returns: { id: "123" }
|
|
34
|
-
// Validates numeric constraint via URLPattern
|
|
35
|
-
|
|
36
|
-
extractParams("/docs/intro", "/docs/*");
|
|
37
|
-
// Returns: { "0": "intro" }
|
|
38
|
-
```
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
[Documentation](../../../README.md) / [@xmachines/play-tanstack-react-router](../README.md) / extractQueryParams
|
|
2
|
-
|
|
3
|
-
# Function: extractQueryParams()
|
|
4
|
-
|
|
5
|
-
```ts
|
|
6
|
-
function extractQueryParams(search): Record<string, string>;
|
|
7
|
-
```
|
|
8
|
-
|
|
9
|
-
Defined in: [play-tanstack-react-router/src/extract-params.ts:68](https://gitlab.com/xmachin-es/xmachines-js/-/blob/v1.0.0-beta.25/packages/play-tanstack-react-router/src/extract-params.ts#L68)
|
|
10
|
-
|
|
11
|
-
Extract query parameters from search string
|
|
12
|
-
|
|
13
|
-
## Parameters
|
|
14
|
-
|
|
15
|
-
| Parameter | Type | Description |
|
|
16
|
-
| --------- | -------- | -------------------------------------------------------------------------------- |
|
|
17
|
-
| `search` | `string` | Query string with or without leading ? (e.g., "?tab=settings" or "tab=settings") |
|
|
18
|
-
|
|
19
|
-
## Returns
|
|
20
|
-
|
|
21
|
-
`Record`\<`string`, `string`\>
|
|
22
|
-
|
|
23
|
-
Object mapping query parameter names to values
|
|
24
|
-
|
|
25
|
-
## Example
|
|
26
|
-
|
|
27
|
-
```typescript
|
|
28
|
-
extractQueryParams("?tab=settings&theme=dark");
|
|
29
|
-
// Returns: { tab: "settings", theme: "dark" }
|
|
30
|
-
|
|
31
|
-
extractQueryParams("q=hello%20world");
|
|
32
|
-
// Returns: { q: "hello world" } (auto-decoded)
|
|
33
|
-
```
|