@xmachines/docs 1.0.0-beta.50 → 1.0.0-beta.52

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.
Files changed (364) hide show
  1. package/README.md +13 -11
  2. package/api/@xmachines/play/README.md +6 -5
  3. package/api/@xmachines/play/classes/NonNullableError.md +4 -4
  4. package/api/@xmachines/play/classes/PlayError.md +4 -4
  5. package/api/@xmachines/play/functions/assertNonNullable.md +1 -1
  6. package/api/@xmachines/play/type-aliases/PlayEvent.md +2 -2
  7. package/api/@xmachines/play-actor/README.md +2 -2
  8. package/api/@xmachines/play-actor/classes/AbstractActor.md +3 -3
  9. package/api/@xmachines/play-actor/functions/typedSpec.md +1 -1
  10. package/api/@xmachines/play-actor/interfaces/BaseActorProviderProps.md +5 -5
  11. package/api/@xmachines/play-actor/interfaces/BaseViewContextValue.md +5 -5
  12. package/api/@xmachines/play-actor/interfaces/PlaySpec.md +2 -2
  13. package/api/@xmachines/play-actor/interfaces/Routable.md +3 -3
  14. package/api/@xmachines/play-actor/interfaces/Viewable.md +2 -2
  15. package/api/@xmachines/play-dom/README.md +125 -47
  16. package/api/@xmachines/play-dom/classes/PlayRenderer.md +20 -10
  17. package/api/@xmachines/play-dom/functions/createPlayUI.md +9 -9
  18. package/api/@xmachines/play-dom/functions/createRenderer.md +3 -2
  19. package/api/@xmachines/play-dom/functions/defineRegistry.md +1 -1
  20. package/api/@xmachines/play-dom/functions/renderSpec.md +17 -13
  21. package/api/@xmachines/play-dom/interfaces/ComponentContext.md +7 -7
  22. package/api/@xmachines/play-dom/interfaces/CreatePlayUIOptions.md +15 -12
  23. package/api/@xmachines/play-dom/interfaces/DefineRegistryResult.md +4 -4
  24. package/api/@xmachines/play-dom/interfaces/DomRenderContext.md +17 -14
  25. package/api/@xmachines/play-dom/interfaces/EventHandle.md +4 -4
  26. package/api/@xmachines/play-dom/interfaces/MountOptions.md +10 -6
  27. package/api/@xmachines/play-dom/interfaces/PlayDomOptions.md +20 -8
  28. package/api/@xmachines/play-dom/interfaces/UIProviderOptions.md +13 -10
  29. package/api/@xmachines/play-dom/type-aliases/ActionFn.md +1 -1
  30. package/api/@xmachines/play-dom/type-aliases/Actions.md +1 -1
  31. package/api/@xmachines/play-dom/type-aliases/BaseComponentProps.md +7 -7
  32. package/api/@xmachines/play-dom/type-aliases/CatalogHasActions.md +1 -1
  33. package/api/@xmachines/play-dom/type-aliases/ComponentFn.md +1 -1
  34. package/api/@xmachines/play-dom/type-aliases/ComponentRegistry.md +1 -1
  35. package/api/@xmachines/play-dom/type-aliases/DefineRegistryOptions.md +2 -2
  36. package/api/@xmachines/play-dom/type-aliases/DomComponentRenderer.md +1 -1
  37. package/api/@xmachines/play-dom/type-aliases/DomRegistry.md +1 -1
  38. package/api/@xmachines/play-dom/type-aliases/DomSchema.md +1 -1
  39. package/api/@xmachines/play-dom/type-aliases/MountFn.md +6 -4
  40. package/api/@xmachines/play-dom/type-aliases/SetState.md +1 -1
  41. package/api/@xmachines/play-dom/variables/schema.md +1 -1
  42. package/api/@xmachines/play-dom-router/README.md +23 -25
  43. package/api/@xmachines/play-dom-router/functions/connectRouter.md +1 -1
  44. package/api/@xmachines/play-dom-router/functions/createBrowserHistory.md +1 -1
  45. package/api/@xmachines/play-dom-router/functions/createRouteMap.md +1 -1
  46. package/api/@xmachines/play-dom-router/functions/createRouter.md +1 -1
  47. package/api/@xmachines/play-dom-router/interfaces/BrowserHistory.md +14 -14
  48. package/api/@xmachines/play-dom-router/interfaces/BrowserWindow.md +14 -14
  49. package/api/@xmachines/play-dom-router/interfaces/ConnectRouterOptions.md +6 -6
  50. package/api/@xmachines/play-dom-router/interfaces/PlayRouteEvent.md +6 -6
  51. package/api/@xmachines/play-dom-router/interfaces/RoutableActor.md +68 -0
  52. package/api/@xmachines/play-dom-router/interfaces/RouteLookupContract.md +3 -3
  53. package/api/@xmachines/play-dom-router/interfaces/RouteMap.md +3 -3
  54. package/api/@xmachines/play-dom-router/interfaces/RouteMapOptions.md +2 -2
  55. package/api/@xmachines/play-dom-router/interfaces/RouteMapping.md +3 -3
  56. package/api/@xmachines/play-dom-router/interfaces/RouterBridge.md +3 -3
  57. package/api/@xmachines/play-dom-router/interfaces/VanillaRouter.md +4 -4
  58. package/api/@xmachines/play-react/README.md +3 -3
  59. package/api/@xmachines/play-react/classes/PlayErrorBoundary.md +5 -5
  60. package/api/@xmachines/play-react/functions/useActor.md +3 -3
  61. package/api/@xmachines/play-react/functions/usePlayView.md +1 -1
  62. package/api/@xmachines/play-react/functions/useSignalEffect.md +1 -1
  63. package/api/@xmachines/play-react/interfaces/ActorProviderProps.md +8 -8
  64. package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryProps.md +4 -4
  65. package/api/@xmachines/play-react/interfaces/PlayErrorBoundaryState.md +3 -3
  66. package/api/@xmachines/play-react/interfaces/PlayUIProviderProps.md +8 -8
  67. package/api/@xmachines/play-react/interfaces/ViewContextValue.md +5 -5
  68. package/api/@xmachines/play-react/type-aliases/AnyPlayActor.md +11 -0
  69. package/api/@xmachines/play-react/variables/ActorProvider.md +1 -1
  70. package/api/@xmachines/play-react/variables/PlayRenderer.md +1 -1
  71. package/api/@xmachines/play-react/variables/PlayUIProvider.md +1 -1
  72. package/api/@xmachines/play-react-router/README.md +16 -1
  73. package/api/@xmachines/play-react-router/classes/ReactRouterBridge.md +85 -41
  74. package/api/@xmachines/play-react-router/classes/RouteMap.md +4 -4
  75. package/api/@xmachines/play-react-router/functions/PlayRouterProvider.md +4 -4
  76. package/api/@xmachines/play-react-router/functions/createRouteMap.md +1 -1
  77. package/api/@xmachines/play-react-router/functions/createRouteMapFromTree.md +1 -1
  78. package/api/@xmachines/play-react-router/interfaces/PlayActor.md +68 -0
  79. package/api/@xmachines/play-react-router/interfaces/PlayRouteEvent.md +6 -6
  80. package/api/@xmachines/play-react-router/interfaces/PlayRouterProviderProps.md +8 -8
  81. package/api/@xmachines/play-react-router/interfaces/RouteMapOptions.md +2 -2
  82. package/api/@xmachines/play-react-router/interfaces/RouteMapping.md +3 -3
  83. package/api/@xmachines/play-react-router/interfaces/RouterBridge.md +3 -3
  84. package/api/@xmachines/play-router/README.md +21 -18
  85. package/api/@xmachines/play-router/classes/RouteMap.md +4 -4
  86. package/api/@xmachines/play-router/classes/RouterBridgeBase.md +83 -43
  87. package/api/@xmachines/play-router/functions/buildPlayRouteEvent.md +1 -1
  88. package/api/@xmachines/play-router/functions/buildRouteTree.md +1 -1
  89. package/api/@xmachines/play-router/functions/createRouteMap.md +1 -1
  90. package/api/@xmachines/play-router/functions/createRouteMapFromTree.md +1 -1
  91. package/api/@xmachines/play-router/functions/createRouteMatcher.md +1 -1
  92. package/api/@xmachines/play-router/functions/detectDuplicateRoutes.md +1 -1
  93. package/api/@xmachines/play-router/functions/extractMachineRoutes.md +1 -1
  94. package/api/@xmachines/play-router/functions/extractQuery.md +1 -1
  95. package/api/@xmachines/play-router/functions/extractRouteParams.md +1 -1
  96. package/api/@xmachines/play-router/functions/findRouteById.md +1 -1
  97. package/api/@xmachines/play-router/functions/findRouteByPath.md +1 -1
  98. package/api/@xmachines/play-router/functions/getNavigableRoutes.md +1 -1
  99. package/api/@xmachines/play-router/functions/getRoutableRoutes.md +1 -1
  100. package/api/@xmachines/play-router/functions/getTransitionReachableRoutes.md +1 -1
  101. package/api/@xmachines/play-router/functions/isRouteReachable.md +1 -1
  102. package/api/@xmachines/play-router/functions/machineToGraph.md +1 -1
  103. package/api/@xmachines/play-router/functions/routeExists.md +1 -1
  104. package/api/@xmachines/play-router/functions/sanitizePathname.md +1 -1
  105. package/api/@xmachines/play-router/functions/validateRouteFormat.md +1 -1
  106. package/api/@xmachines/play-router/functions/validateStateExists.md +1 -1
  107. package/api/@xmachines/play-router/interfaces/BuildPlayRouteEventOptions.md +4 -4
  108. package/api/@xmachines/play-router/interfaces/LocationLike.md +3 -3
  109. package/api/@xmachines/play-router/interfaces/MachineEdgeData.md +3 -3
  110. package/api/@xmachines/play-router/interfaces/MachineNodeData.md +5 -5
  111. package/api/@xmachines/play-router/interfaces/PlayActor.md +68 -0
  112. package/api/@xmachines/play-router/interfaces/PlayRouteEvent.md +6 -6
  113. package/api/@xmachines/play-router/interfaces/RoutableActor.md +64 -0
  114. package/api/@xmachines/play-router/interfaces/RouteInfo.md +8 -8
  115. package/api/@xmachines/play-router/interfaces/RouteMapOptions.md +2 -2
  116. package/api/@xmachines/play-router/interfaces/RouteMapping.md +3 -3
  117. package/api/@xmachines/play-router/interfaces/RouteMatch.md +3 -3
  118. package/api/@xmachines/play-router/interfaces/RouteMatcher.md +4 -4
  119. package/api/@xmachines/play-router/interfaces/RouteNode.md +10 -10
  120. package/api/@xmachines/play-router/interfaces/RouteObject.md +2 -2
  121. package/api/@xmachines/play-router/interfaces/RouteTree.md +5 -5
  122. package/api/@xmachines/play-router/interfaces/RouteWatcherHandle.md +3 -3
  123. package/api/@xmachines/play-router/interfaces/RouterBridge.md +3 -3
  124. package/api/@xmachines/play-router/interfaces/WindowLike.md +3 -3
  125. package/api/@xmachines/play-router/type-aliases/MachineGraph.md +1 -1
  126. package/api/@xmachines/play-router/type-aliases/RouteMetadata.md +1 -1
  127. package/api/@xmachines/play-signals/README.md +4 -3
  128. package/api/@xmachines/play-signals/functions/watchSignal.md +1 -1
  129. package/api/@xmachines/play-signals/interfaces/ComputedOptions.md +2 -2
  130. package/api/@xmachines/play-signals/interfaces/SignalComputed.md +2 -2
  131. package/api/@xmachines/play-signals/interfaces/SignalOptions.md +2 -2
  132. package/api/@xmachines/play-signals/interfaces/SignalState.md +3 -3
  133. package/api/@xmachines/play-signals/interfaces/SignalWatcher.md +4 -4
  134. package/api/@xmachines/play-signals/type-aliases/WatcherNotify.md +1 -1
  135. package/api/@xmachines/play-solid/README.md +18 -20
  136. package/api/@xmachines/play-solid/functions/useActor.md +3 -3
  137. package/api/@xmachines/play-solid/functions/usePlayView.md +1 -1
  138. package/api/@xmachines/play-solid/interfaces/ActorProviderProps.md +8 -8
  139. package/api/@xmachines/play-solid/interfaces/PlayUIProviderProps.md +8 -8
  140. package/api/@xmachines/play-solid/interfaces/ViewContextValue.md +5 -5
  141. package/api/@xmachines/play-solid/type-aliases/AnyPlayActor.md +11 -0
  142. package/api/@xmachines/play-solid/variables/ActorContext.md +2 -2
  143. package/api/@xmachines/play-solid/variables/ActorProvider.md +1 -1
  144. package/api/@xmachines/play-solid/variables/PlayRenderer.md +1 -1
  145. package/api/@xmachines/play-solid/variables/PlayUIProvider.md +1 -1
  146. package/api/@xmachines/play-solid-router/README.md +77 -10
  147. package/api/@xmachines/play-solid-router/classes/RouteMap.md +4 -4
  148. package/api/@xmachines/play-solid-router/classes/SolidRouterBridge.md +83 -35
  149. package/api/@xmachines/play-solid-router/functions/PlayRouterProvider.md +4 -4
  150. package/api/@xmachines/play-solid-router/functions/createRouteMap.md +1 -1
  151. package/api/@xmachines/play-solid-router/interfaces/AbstractActor.md +3 -3
  152. package/api/@xmachines/play-solid-router/interfaces/PlayActor.md +68 -0
  153. package/api/@xmachines/play-solid-router/interfaces/PlayRouteEvent.md +6 -6
  154. package/api/@xmachines/play-solid-router/interfaces/PlayRouterProviderProps.md +8 -8
  155. package/api/@xmachines/play-solid-router/interfaces/RouteMapOptions.md +2 -2
  156. package/api/@xmachines/play-solid-router/interfaces/RouteMapping.md +3 -3
  157. package/api/@xmachines/play-solid-router/interfaces/RouterBridge.md +3 -3
  158. package/api/@xmachines/play-solid-router/type-aliases/RoutableActor.md +6 -4
  159. package/api/@xmachines/play-solid-router/type-aliases/SolidRouterHooks.md +4 -4
  160. package/api/@xmachines/play-svelte/README.md +23 -14
  161. package/api/@xmachines/play-svelte/functions/defineRegistry.md +1 -1
  162. package/api/@xmachines/play-svelte/functions/getActorContext.md +3 -3
  163. package/api/@xmachines/play-svelte/functions/getPlayViewContext.md +1 -1
  164. package/api/@xmachines/play-svelte/functions/setActorContext.md +4 -4
  165. package/api/@xmachines/play-svelte/interfaces/ActorProviderProps.md +8 -8
  166. package/api/@xmachines/play-svelte/interfaces/DefineRegistryOptions.md +4 -4
  167. package/api/@xmachines/play-svelte/interfaces/PlayUIProviderProps.md +11 -11
  168. package/api/@xmachines/play-svelte/interfaces/ViewContextValue.md +5 -5
  169. package/api/@xmachines/play-svelte/type-aliases/AnyPlayActor.md +11 -0
  170. package/api/@xmachines/play-svelte-spa-router/README.md +13 -13
  171. package/api/@xmachines/play-svelte-spa-router/classes/RouteMap.md +4 -4
  172. package/api/@xmachines/play-svelte-spa-router/functions/connectRouter.md +1 -1
  173. package/api/@xmachines/play-svelte-spa-router/functions/createRouteMap.md +1 -1
  174. package/api/@xmachines/play-svelte-spa-router/interfaces/ConnectRouterOptions.md +6 -6
  175. package/api/@xmachines/play-svelte-spa-router/interfaces/PlayRouteEvent.md +6 -6
  176. package/api/@xmachines/play-svelte-spa-router/interfaces/RouteMapOptions.md +2 -2
  177. package/api/@xmachines/play-svelte-spa-router/interfaces/RouteMapping.md +3 -3
  178. package/api/@xmachines/play-svelte-spa-router/interfaces/RouterBridge.md +3 -3
  179. package/api/@xmachines/play-svelte-spa-router/interfaces/WindowLike.md +3 -3
  180. package/api/@xmachines/play-svelte-spa-router/type-aliases/RoutableActor.md +1 -1
  181. package/api/@xmachines/play-sveltekit-router/README.md +20 -20
  182. package/api/@xmachines/play-sveltekit-router/classes/RouteMap.md +4 -4
  183. package/api/@xmachines/play-sveltekit-router/functions/connectRouter.md +1 -1
  184. package/api/@xmachines/play-sveltekit-router/functions/createRouteMap.md +1 -1
  185. package/api/@xmachines/play-sveltekit-router/interfaces/ConnectRouterOptions.md +6 -6
  186. package/api/@xmachines/play-sveltekit-router/interfaces/LocationLike.md +3 -3
  187. package/api/@xmachines/play-sveltekit-router/interfaces/PlayRouteEvent.md +6 -6
  188. package/api/@xmachines/play-sveltekit-router/interfaces/RouteMapOptions.md +2 -2
  189. package/api/@xmachines/play-sveltekit-router/interfaces/RouteMapping.md +3 -3
  190. package/api/@xmachines/play-sveltekit-router/interfaces/RouterBridge.md +3 -3
  191. package/api/@xmachines/play-sveltekit-router/type-aliases/RoutableActor.md +1 -1
  192. package/api/@xmachines/play-tanstack-react-router/README.md +3 -6
  193. package/api/@xmachines/play-tanstack-react-router/classes/RouteMap.md +4 -4
  194. package/api/@xmachines/play-tanstack-react-router/classes/TanStackReactRouterBridge.md +80 -35
  195. package/api/@xmachines/play-tanstack-react-router/functions/PlayRouterProvider.md +4 -4
  196. package/api/@xmachines/play-tanstack-react-router/functions/createRouteMap.md +1 -1
  197. package/api/@xmachines/play-tanstack-react-router/functions/createRouteMapFromTree.md +1 -1
  198. package/api/@xmachines/play-tanstack-react-router/functions/extractMachineRoutes.md +1 -1
  199. package/api/@xmachines/play-tanstack-react-router/interfaces/PlayActor.md +68 -0
  200. package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouteEvent.md +6 -6
  201. package/api/@xmachines/play-tanstack-react-router/interfaces/PlayRouterProviderProps.md +8 -8
  202. package/api/@xmachines/play-tanstack-react-router/interfaces/RouteMapOptions.md +2 -2
  203. package/api/@xmachines/play-tanstack-react-router/interfaces/RouteMapping.md +3 -3
  204. package/api/@xmachines/play-tanstack-react-router/interfaces/RouteNavigateEvent.md +3 -3
  205. package/api/@xmachines/play-tanstack-react-router/interfaces/RouterBridge.md +3 -3
  206. package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterInstance.md +1 -1
  207. package/api/@xmachines/play-tanstack-react-router/type-aliases/TanStackRouterLike.md +4 -4
  208. package/api/@xmachines/play-tanstack-solid-router/README.md +23 -17
  209. package/api/@xmachines/play-tanstack-solid-router/classes/RouteMap.md +4 -4
  210. package/api/@xmachines/play-tanstack-solid-router/classes/{SolidRouterBridge.md → TanStackSolidRouterBridge.md} +86 -38
  211. package/api/@xmachines/play-tanstack-solid-router/functions/PlayRouterProvider.md +4 -4
  212. package/api/@xmachines/play-tanstack-solid-router/functions/createRouteMap.md +1 -1
  213. package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayActor.md +68 -0
  214. package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouteEvent.md +6 -6
  215. package/api/@xmachines/play-tanstack-solid-router/interfaces/PlayRouterProviderProps.md +8 -8
  216. package/api/@xmachines/play-tanstack-solid-router/interfaces/RouteMapOptions.md +2 -2
  217. package/api/@xmachines/play-tanstack-solid-router/interfaces/RouteMapping.md +3 -3
  218. package/api/@xmachines/play-tanstack-solid-router/interfaces/RouterBridge.md +3 -3
  219. package/api/@xmachines/play-tanstack-solid-router/type-aliases/RoutableActor.md +6 -4
  220. package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterInstance.md +2 -2
  221. package/api/@xmachines/play-tanstack-solid-router/type-aliases/TanStackRouterLike.md +3 -3
  222. package/api/@xmachines/play-vue/README.md +3 -3
  223. package/api/@xmachines/play-vue/functions/defineRegistry.md +1 -1
  224. package/api/@xmachines/play-vue/functions/getPlayViewContext.md +1 -1
  225. package/api/@xmachines/play-vue/functions/useActor.md +3 -3
  226. package/api/@xmachines/play-vue/interfaces/ActorProviderProps.md +5 -5
  227. package/api/@xmachines/play-vue/interfaces/PlayUIProviderProps.md +8 -8
  228. package/api/@xmachines/play-vue/interfaces/ViewContextValue.md +5 -5
  229. package/api/@xmachines/play-vue/interfaces/VisibilityProviderProps.md +1 -1
  230. package/api/@xmachines/play-vue/type-aliases/AnyPlayActor.md +11 -0
  231. package/api/@xmachines/play-vue/type-aliases/ComponentEntry.md +1 -1
  232. package/api/@xmachines/play-vue/type-aliases/ComponentsMap.md +1 -1
  233. package/api/@xmachines/play-vue/type-aliases/DefineRegistryOptions.md +2 -2
  234. package/api/@xmachines/play-vue/variables/PlayRenderer.md +1 -1
  235. package/api/@xmachines/play-vue-router/README.md +27 -17
  236. package/api/@xmachines/play-vue-router/classes/RouteMap.md +4 -4
  237. package/api/@xmachines/play-vue-router/classes/VueRouterBridge.md +81 -33
  238. package/api/@xmachines/play-vue-router/functions/createRouteMap.md +1 -1
  239. package/api/@xmachines/play-vue-router/interfaces/PlayActor.md +68 -0
  240. package/api/@xmachines/play-vue-router/interfaces/PlayRouteEvent.md +6 -6
  241. package/api/@xmachines/play-vue-router/interfaces/RouteMapOptions.md +2 -2
  242. package/api/@xmachines/play-vue-router/interfaces/RouteMapping.md +3 -3
  243. package/api/@xmachines/play-vue-router/interfaces/RouterBridge.md +3 -3
  244. package/api/@xmachines/play-vue-router/type-aliases/RoutableActor.md +6 -4
  245. package/api/@xmachines/play-vue-router/variables/PlayRouterProvider.md +3 -3
  246. package/api/@xmachines/play-xstate/README.md +7 -3
  247. package/api/@xmachines/play-xstate/classes/PlayerActor.md +12 -12
  248. package/api/@xmachines/play-xstate/functions/buildRouteUrl.md +1 -1
  249. package/api/@xmachines/play-xstate/functions/composeGuards.md +1 -1
  250. package/api/@xmachines/play-xstate/functions/composeGuardsOr.md +1 -1
  251. package/api/@xmachines/play-xstate/functions/contextFieldMatches.md +1 -1
  252. package/api/@xmachines/play-xstate/functions/definePlayer.md +1 -1
  253. package/api/@xmachines/play-xstate/functions/deriveRoute.md +1 -1
  254. package/api/@xmachines/play-xstate/functions/eventMatches.md +1 -1
  255. package/api/@xmachines/play-xstate/functions/formatPlayRouteTransitions.md +1 -1
  256. package/api/@xmachines/play-xstate/functions/hasContext.md +1 -1
  257. package/api/@xmachines/play-xstate/functions/isAbsoluteRoute.md +1 -1
  258. package/api/@xmachines/play-xstate/functions/negateGuard.md +1 -1
  259. package/api/@xmachines/play-xstate/interfaces/PlayerConfig.md +3 -3
  260. package/api/@xmachines/play-xstate/interfaces/PlayerFactoryResumeOptions.md +2 -2
  261. package/api/@xmachines/play-xstate/interfaces/PlayerOptions.md +6 -6
  262. package/api/@xmachines/play-xstate/interfaces/RouteContext.md +5 -5
  263. package/api/@xmachines/play-xstate/interfaces/RouteObject.md +17 -0
  264. package/api/@xmachines/play-xstate/type-aliases/ComposedGuard.md +1 -1
  265. package/api/@xmachines/play-xstate/type-aliases/Guard.md +1 -1
  266. package/api/@xmachines/play-xstate/type-aliases/GuardArray.md +1 -1
  267. package/api/@xmachines/play-xstate/type-aliases/PlayerFactory.md +1 -1
  268. package/api/@xmachines/play-xstate/type-aliases/RouteMachineConfig.md +4 -4
  269. package/api/@xmachines/play-xstate/type-aliases/RouteMetadata.md +9 -0
  270. package/api/@xmachines/play-xstate/type-aliases/RouteStateNode.md +4 -4
  271. package/api/@xmachines/shared/README.md +25 -12
  272. package/api/@xmachines/shared/vite-aliases/functions/xmAliases.md +1 -1
  273. package/api/@xmachines/shared/vite-aliases/functions/xmCacheDir.md +1 -1
  274. package/api/@xmachines/shared/vite-aliases/functions/xmOptimizeDeps.md +1 -1
  275. package/api/@xmachines/shared/vite-aliases/functions/xmResolve.md +1 -1
  276. package/api/@xmachines/shared/vitest/functions/defineXmVitestConfig.md +1 -1
  277. package/contributing/architecture.md +599 -0
  278. package/contributing/configuration.md +262 -419
  279. package/contributing/development.md +300 -453
  280. package/contributing/testing.md +165 -172
  281. package/examples/@xmachines/play-dom-demo/README.md +30 -21
  282. package/examples/@xmachines/play-dom-demo/functions/createNavBar.md +1 -1
  283. package/examples/@xmachines/play-dom-demo/functions/initShell.md +1 -1
  284. package/examples/@xmachines/play-dom-demo/type-aliases/AuthCatalog.md +1 -1
  285. package/examples/@xmachines/play-dom-demo/variables/About.md +1 -1
  286. package/examples/@xmachines/play-dom-demo/variables/Contact.md +1 -1
  287. package/examples/@xmachines/play-dom-demo/variables/Dashboard.md +1 -1
  288. package/examples/@xmachines/play-dom-demo/variables/Home.md +1 -1
  289. package/examples/@xmachines/play-dom-demo/variables/Login.md +1 -1
  290. package/examples/@xmachines/play-dom-demo/variables/NavBarView.md +1 -1
  291. package/examples/@xmachines/play-dom-demo/variables/Navigation.md +1 -1
  292. package/examples/@xmachines/play-dom-demo/variables/Overview.md +1 -1
  293. package/examples/@xmachines/play-dom-demo/variables/Profile.md +1 -1
  294. package/examples/@xmachines/play-dom-demo/variables/Settings.md +1 -1
  295. package/examples/@xmachines/play-dom-demo/variables/Stats.md +1 -1
  296. package/examples/@xmachines/play-dom-demo/variables/authCatalog.md +1 -1
  297. package/examples/@xmachines/play-dom-router-demo/README.md +23 -18
  298. package/examples/@xmachines/play-react-demo/README.md +38 -37
  299. package/examples/@xmachines/play-react-demo/functions/App.md +1 -1
  300. package/examples/@xmachines/play-react-demo/type-aliases/AuthCatalog.md +1 -1
  301. package/examples/@xmachines/play-react-demo/variables/About.md +1 -1
  302. package/examples/@xmachines/play-react-demo/variables/Contact.md +1 -1
  303. package/examples/@xmachines/play-react-demo/variables/Dashboard.md +1 -1
  304. package/examples/@xmachines/play-react-demo/variables/DebugPanel.md +1 -1
  305. package/examples/@xmachines/play-react-demo/variables/Home.md +1 -1
  306. package/examples/@xmachines/play-react-demo/variables/Login.md +1 -1
  307. package/examples/@xmachines/play-react-demo/variables/NavBar.md +1 -1
  308. package/examples/@xmachines/play-react-demo/variables/NavBarView.md +1 -1
  309. package/examples/@xmachines/play-react-demo/variables/Navigation.md +1 -1
  310. package/examples/@xmachines/play-react-demo/variables/Overview.md +1 -1
  311. package/examples/@xmachines/play-react-demo/variables/Profile.md +1 -1
  312. package/examples/@xmachines/play-react-demo/variables/Settings.md +1 -1
  313. package/examples/@xmachines/play-react-demo/variables/Shell.md +1 -1
  314. package/examples/@xmachines/play-react-demo/variables/Stats.md +1 -1
  315. package/examples/@xmachines/play-react-demo/variables/authCatalog.md +1 -1
  316. package/examples/@xmachines/play-react-router-demo/README.md +37 -33
  317. package/examples/@xmachines/play-solid-demo/README.md +5 -2
  318. package/examples/@xmachines/play-solid-demo/functions/App.md +1 -1
  319. package/examples/@xmachines/play-solid-demo/type-aliases/AuthCatalog.md +1 -1
  320. package/examples/@xmachines/play-solid-demo/variables/About.md +1 -1
  321. package/examples/@xmachines/play-solid-demo/variables/Contact.md +1 -1
  322. package/examples/@xmachines/play-solid-demo/variables/Dashboard.md +1 -1
  323. package/examples/@xmachines/play-solid-demo/variables/DebugPanel.md +1 -1
  324. package/examples/@xmachines/play-solid-demo/variables/Home.md +1 -1
  325. package/examples/@xmachines/play-solid-demo/variables/Login.md +1 -1
  326. package/examples/@xmachines/play-solid-demo/variables/NavBar.md +1 -1
  327. package/examples/@xmachines/play-solid-demo/variables/NavBarView.md +1 -1
  328. package/examples/@xmachines/play-solid-demo/variables/Navigation.md +1 -1
  329. package/examples/@xmachines/play-solid-demo/variables/Overview.md +1 -1
  330. package/examples/@xmachines/play-solid-demo/variables/Profile.md +1 -1
  331. package/examples/@xmachines/play-solid-demo/variables/Settings.md +1 -1
  332. package/examples/@xmachines/play-solid-demo/variables/Shell.md +1 -1
  333. package/examples/@xmachines/play-solid-demo/variables/Stats.md +1 -1
  334. package/examples/@xmachines/play-solid-demo/variables/authCatalog.md +1 -1
  335. package/examples/@xmachines/play-solid-router-demo/README.md +38 -25
  336. package/examples/@xmachines/play-svelte-demo/README.md +8 -5
  337. package/examples/@xmachines/play-svelte-demo/type-aliases/AuthCatalog.md +1 -1
  338. package/examples/@xmachines/play-svelte-demo/variables/authCatalog.md +1 -1
  339. package/examples/@xmachines/play-svelte-spa-router-demo/README.md +11 -9
  340. package/examples/@xmachines/play-sveltekit-router-demo/README.md +14 -9
  341. package/examples/@xmachines/play-tanstack-react-router-demo/README.md +39 -13
  342. package/examples/@xmachines/play-tanstack-solid-router-demo/README.md +27 -13
  343. package/examples/@xmachines/play-vue-demo/README.md +35 -24
  344. package/examples/@xmachines/play-vue-demo/type-aliases/AuthCatalog.md +1 -1
  345. package/examples/@xmachines/play-vue-demo/variables/App.md +1 -1
  346. package/examples/@xmachines/play-vue-demo/variables/authCatalog.md +1 -1
  347. package/examples/@xmachines/play-vue-router-demo/README.md +2 -0
  348. package/examples/README.md +7 -7
  349. package/examples/multi-router-integration.md +13 -16
  350. package/examples/routing-patterns.md +2 -2
  351. package/guides/README.md +1 -1
  352. package/guides/actor-model.md +2 -2
  353. package/guides/getting-started.md +325 -132
  354. package/guides/signals.md +1 -1
  355. package/guides/state-machines.md +1 -1
  356. package/package.json +2 -2
  357. package/api/@xmachines/play-dom/functions/connectRenderer.md +0 -70
  358. package/api/@xmachines/play-dom/interfaces/ConnectRendererOptions.md +0 -28
  359. package/api/@xmachines/play-dom-router/type-aliases/RoutableActor.md +0 -9
  360. package/api/@xmachines/play-react/type-aliases/PlayActor.md +0 -9
  361. package/api/@xmachines/play-solid/type-aliases/PlayActor.md +0 -9
  362. package/api/@xmachines/play-svelte/type-aliases/PlayActor.md +0 -9
  363. package/api/@xmachines/play-vue/type-aliases/PlayActor.md +0 -9
  364. package/guides/architecture.md +0 -500
@@ -1,62 +1,56 @@
1
1
  <!-- generated-by: gsd-doc-writer -->
2
2
 
3
- # Development Guide
3
+ # Development
4
4
 
5
- This guide covers everything you need to contribute to the XMachines JS monorepo from setting up your environment through the full build, test, lint, and release lifecycle.
5
+ This guide covers everything you need to set up a local development environment, understand the build system, and contribute code to the XMachines JS monorepo.
6
6
 
7
- ---
8
-
9
- ## Prerequisites
7
+ ## Table of Contents
10
8
 
11
- | Requirement | Version | Notes |
12
- | ----------- | -------------------- | -------------------------------------------------------- |
13
- | Node.js | `>= 22.0.0` | Specified in all `package.json` `engines` fields |
14
- | npm | Bundled with Node 22 | Workspaces support required |
15
- | TypeScript | `^5.7+` | Installed as a dev dependency — no global install needed |
16
- | Git | Any recent version | Commit message format enforced by CI |
17
-
18
- No global tool installs are required beyond Node.js. All build, lint, and format tooling is installed locally via `npm ci`.
9
+ - [Local Setup](#local-setup)
10
+ - [Monorepo Structure](#monorepo-structure)
11
+ - [Build Commands](#build-commands)
12
+ - [TypeScript Composite Build System](#typescript-composite-build-system)
13
+ - [Code Style](#code-style)
14
+ - [Branch Conventions](#branch-conventions)
15
+ - [PR Process](#pr-process)
19
16
 
20
17
  ---
21
18
 
22
19
  ## Local Setup
23
20
 
24
- ### 1. Clone the repository
21
+ ### Prerequisites
25
22
 
26
- ```bash
27
- git clone git@gitlab.com:xmachin-es/xmachines-js.git
28
- cd xmachines-js
29
- ```
23
+ - **Node.js** `>= 22.0.0`
24
+ - **npm** (bundled with Node.js — the project uses npm workspaces)
25
+ - **Git**
30
26
 
31
- ### 2. Install dependencies
27
+ No global tool installs are required beyond Node.js. All build, lint, and format tooling is installed locally via `npm ci`.
32
28
 
33
- Always use `npm ci` (not `npm install`) so the lockfile is respected:
29
+ ### Clone and Install
34
30
 
35
31
  ```bash
32
+ git clone git@gitlab.com:xmachin-es/xmachines-js.git
33
+ cd xmachines-js
36
34
  npm ci
37
35
  ```
38
36
 
39
- `postinstall` automatically runs `patch-package` to apply the patches in `patches/` — this is expected and required.
37
+ > **Use `npm ci`, not `npm install`.** `npm ci` installs exact locked versions and triggers the `postinstall` hook that runs `patch-package` to apply any repository patches.
40
38
 
41
- ### 3. Build all packages
39
+ ### Build
42
40
 
43
41
  ```bash
44
42
  npm run build
45
43
  ```
46
44
 
47
- The build uses TypeScript project references (`tsc --build`) and compiles all packages in dependency order. Build outputs go to each package's `dist/` directory. The `dist/` directories are gitignored.
45
+ The root-level `tsc --build` command uses TypeScript project references to build all packages in the correct dependency order automatically. You never need to sequence builds manually.
48
46
 
49
- ### 4. Verify
47
+ To build a single package (and its upstream dependencies):
50
48
 
51
49
  ```bash
52
- npm test
50
+ npm run build -w @xmachines/<package-name>
53
51
  ```
54
52
 
55
- All tests should pass on a clean install. If any fail, check the [Common Setup Issues](#common-setup-issues) section.
56
-
57
- ---
58
-
59
- ## Dev Container (Optional)
53
+ ### Dev Container (Optional)
60
54
 
61
55
  A fully configured dev container is provided at `.devcontainer/`. It includes Docker-outside-of-Docker, Claude Code, and OpenCode.
62
56
 
@@ -66,6 +60,16 @@ npm run devcontainer:up
66
60
 
67
61
  Or open the repository in VS Code and choose **Reopen in Container** when prompted.
68
62
 
63
+ ### Verify Your Setup
64
+
65
+ ```bash
66
+ npm test # Run the full test suite
67
+ npm run lint # Check for lint errors
68
+ npm run format:check # Check formatting without modifying files
69
+ ```
70
+
71
+ All three should pass without errors on a freshly cloned repository.
72
+
69
73
  ---
70
74
 
71
75
  ## Monorepo Structure
@@ -98,220 +102,229 @@ packages/
98
102
 
99
103
  Many packages also contain an `examples/` subdirectory with runnable demo apps.
100
104
 
101
- ### Package naming convention
102
-
103
- All packages use the `@xmachines/` npm scope. The package directory name matches the npm name without the scope:
104
-
105
- - `packages/play` → [`@xmachines/play`](../api/@xmachines/play/README.md)
106
- - `packages/play-actor` → [`@xmachines/play-actor`](../api/@xmachines/play-actor/README.md)
107
-
108
- ### Standard package layout
105
+ ### Standard Package Layout
109
106
 
110
107
  ```
111
108
  packages/<name>/
112
- ├── src/ # TypeScript source files
113
- ├── dist/ # Build output (gitignored)
114
- ├── test/ # Test files (*.spec.ts or *.test.ts)
115
- ├── examples/ # Runnable demo apps (optional)
116
- ├── package.json # Must have "type": "module"
117
- ├── tsconfig.json # Extends shared base config
109
+ ├── src/ # TypeScript source files
110
+ ├── dist/ # Build output (gitignored)
111
+ ├── test/ # Test files (*.spec.ts or *.test.ts)
112
+ ├── examples/ # Runnable demo apps (optional)
113
+ ├── package.json # Must have "type": "module"
114
+ ├── tsconfig.json # Composite build config (extends tsconfig.base.json)
118
115
  ├── tsconfig.base.json # Local base (extends @xmachines/shared/tsconfig)
119
- ├── vitest.config.ts # Package test config
116
+ ├── vitest.config.ts # Package test config
120
117
  └── README.md
121
118
  ```
122
119
 
123
120
  ---
124
121
 
125
- ## Build System
126
-
127
- ### Build commands
128
-
129
- | Command | Description |
130
- | ---------------------------------- | ---------------------------------------------------------- |
131
- | `npm run build` | Build all packages in dependency order (incremental) |
132
- | `npm run build -w packages/<name>` | Build a specific package (and its deps) |
133
- | `npm run test:build` | Type-check the full test TypeScript graph without emitting |
134
- | `npm run clean` | Remove all build outputs and caches across all packages |
135
-
136
- ### TypeScript composite build
137
-
138
- This monorepo uses **TypeScript project references** (`composite: true`) for build-order management.
139
-
140
- - **`tsconfig.json`** at the root coordinates all packages via its `references` array — it does not compile anything itself
141
- - Each package's `tsconfig.json` sets `composite: true`, `rootDir: "./src"`, and `outDir: "./dist"`
142
- - TypeScript understands the full dependency graph and builds packages in the correct order automatically
143
- - Incremental builds: only changed packages are rebuilt
144
- - `declarationMap: true` is set in the base config **Go to Definition** in your IDE jumps to source `.ts` files, not compiled `.d.ts`
145
-
146
- **Dependency layers** (from `tsconfig.json`):
147
-
148
- | Layer | Packages |
149
- | ------- | --------------------------------------------------------------------- |
150
- | Layer 0 | `play-signals`, `play`, `docs` — no internal dependencies |
151
- | Layer 1 | `play-actor` — depends on Layer 0 |
152
- | Layer 2 | `play-router`, `play-xstate`, all view renderers, all router adapters |
153
- | Layer 3 | Example applications |
122
+ ## Build Commands
123
+
124
+ All commands are run from the **repository root** unless otherwise noted.
125
+
126
+ | Command | Description |
127
+ | ----------------------------------- | --------------------------------------------------------------------- |
128
+ | `npm run build` | TypeScript composite build — all packages in dependency order |
129
+ | `npm run build -w @xmachines/<pkg>` | Build a single package (and its deps) |
130
+ | `npm run clean` | Remove coverage, Vite caches, and all `dist/` directories in packages |
131
+ | `npm test` | Run all unit/integration tests once |
132
+ | `npm run test:watch` | Re-run tests on file changes (interactive) |
133
+ | `npm run test:browser` | Run Playwright browser tests |
134
+ | `npm run test:coverage` | Run tests with V8 coverage reporting |
135
+ | `npm run coverage:report` | Run tests and write an HTML coverage report |
136
+ | `npm run coverage:summary` | Run tests and write a JSON summary report |
137
+ | `npm run test:build` | Type-check test files without running them (`tsconfig.test.json`) |
138
+ | `npm run lint` | Lint all packages with oxlint |
139
+ | `npm run lint:fix` | Auto-fix lint issues |
140
+ | `npm run format` | Format all files with oxfmt |
141
+ | `npm run format:check` | Check formatting (CI modeno writes) |
142
+ | `npm run docs` | Build packages, generate TypeDoc API docs, then format |
154
143
 
155
144
  ---
156
145
 
157
- ## Adding a New Package
158
-
159
- Follow these steps when creating a new package:
160
-
161
- ### 1. Create the package directory
146
+ ## TypeScript Composite Build System
147
+
148
+ The monorepo uses **TypeScript project references** for correct build-order management. No manual sequencing or separate build scripts are needed.
149
+
150
+ ### How It Works
151
+
152
+ - The **root `tsconfig.json`** coordinates all packages via a `references` array — it compiles nothing itself
153
+ - Each package has `composite: true` in its own `tsconfig.json`, enabling incremental and referenced builds
154
+ - Packages declare `references` to their `@xmachines/*` dependencies so `tsc --build` resolves order automatically
155
+ - With `declarationMap: true` in the base config, **Go to Definition** in your IDE navigates to `.ts` source files rather than compiled `.d.ts` files
156
+
157
+ ### Build Layers
158
+
159
+ Packages are grouped into dependency layers as defined in the root `tsconfig.json`:
160
+
161
+ | Layer | Packages | Depends on |
162
+ | ----- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ |
163
+ | 0 | `play-signals`, `play`, `docs` | External libs only |
164
+ | 1 | `play-actor` | Layer 0 |
165
+ | 2 | `play-router`, `play-dom-router`, `play-sveltekit-router`, `play-xstate`, `play-react`, `play-vue`, `play-solid`, `play-svelte`, `play-dom`, `play-tanstack-react-router`, `play-vue-router`, `play-solid-router`, `play-svelte-spa-router`, `play-tanstack-solid-router` | Layers 0–1 |
166
+ | 3 | `play-react-router`, example demo apps | Layer 2 |
167
+
168
+ #### Mermaid Diagram
169
+
170
+ ```mermaid
171
+ flowchart LR
172
+ subgraph L0["Layer 0 — no internal deps"]
173
+ play-signals
174
+ play
175
+ docs
176
+ end
177
+
178
+ subgraph L1["Layer 1"]
179
+ play-actor
180
+ end
181
+
182
+ subgraph L2["Layer 2 — view renderers & router adapters"]
183
+ play-router
184
+ play-dom-router
185
+ play-sveltekit-router
186
+ play-xstate
187
+ play-react
188
+ play-vue
189
+ play-solid
190
+ play-svelte
191
+ play-dom
192
+ play-tanstack-react-router
193
+ play-vue-router
194
+ play-solid-router
195
+ play-svelte-spa-router
196
+ play-tanstack-solid-router
197
+ end
198
+
199
+ subgraph L3["Layer 3 — application layer"]
200
+ play-react-router
201
+ examples["example demo apps"]
202
+ end
203
+
204
+ L0 --> L1
205
+ L1 --> L2
206
+ L2 --> L3
207
+ ```
208
+
209
+ ### Adding a New Package
210
+
211
+ 1. **Create the package directory** following the standard structure:
212
+
213
+ ```
214
+ packages/<your-package>/
215
+ ├── src/
216
+ │ └── index.ts
217
+ ├── test/
218
+ ├── package.json # must have "type": "module"
219
+ ├── tsconfig.json
220
+ ├── tsconfig.base.json
221
+ ├── vitest.config.ts
222
+ └── README.md
223
+ ```
224
+
225
+ 2. **`tsconfig.base.json`** — extend the shared config:
226
+
227
+ ```json
228
+ {
229
+ "$schema": "https://json.schemastore.org/tsconfig",
230
+ "extends": "@xmachines/shared/tsconfig",
231
+ "compilerOptions": {
232
+ "skipLibCheck": true
233
+ }
234
+ }
235
+ ```
236
+
237
+ If the package depends on other monorepo packages, add `references`:
238
+
239
+ ```json
240
+ {
241
+ "extends": "@xmachines/shared/tsconfig",
242
+ "compilerOptions": { "skipLibCheck": true },
243
+ "references": [{ "path": "../play" }, { "path": "../play-actor" }]
244
+ }
245
+ ```
246
+
247
+ 3. **`tsconfig.json`** — enable composite build:
248
+
249
+ ```json
250
+ {
251
+ "$schema": "https://json.schemastore.org/tsconfig",
252
+ "extends": "./tsconfig.base.json",
253
+ "compilerOptions": {
254
+ "composite": true,
255
+ "rootDir": "./src",
256
+ "outDir": "./dist"
257
+ },
258
+ "include": ["src/**/*"]
259
+ }
260
+ ```
261
+
262
+ 4. **Register in root `tsconfig.json`** — add a reference in the correct layer:
263
+
264
+ ```json
265
+ {
266
+ "references": [{ "path": "./packages/your-package" }]
267
+ }
268
+ ```
269
+
270
+ 5. **Register in root `tsconfig.test.json`** and **root `vitest.config.ts`** (`projects` array).
162
271
 
163
- ```bash
164
- mkdir packages/my-new-package
165
- ```
166
-
167
- ### 2. Create `package.json`
168
-
169
- Must include `"type": "module"` and follow the standard scripts pattern:
170
-
171
- ```json
172
- {
173
- "name": "@xmachines/my-new-package",
174
- "version": "1.0.0-beta.46",
175
- "type": "module",
176
- "exports": {
177
- ".": {
178
- "source": "./src/index.ts",
179
- "types": "./dist/index.d.ts",
180
- "import": "./dist/index.js"
181
- }
182
- },
183
- "scripts": {
184
- "build": "tsc --build",
185
- "clean": "rm -rf dist *.tsbuildinfo coverage",
186
- "test": "vitest",
187
- "lint": "oxlint .",
188
- "lint:fix": "oxlint --fix .",
189
- "format": "oxfmt .",
190
- "format:check": "oxfmt --check .",
191
- "prepublishOnly": "npm run build"
192
- },
193
- "devDependencies": {
194
- "@xmachines/shared": "1.0.0-beta.46",
195
- "oxfmt": "^0.45.0",
196
- "oxlint": "^1.60.0",
197
- "vitest": "^4.1.4"
198
- },
199
- "engines": {
200
- "node": ">=22.0.0"
201
- }
202
- }
203
- ```
272
+ ---
204
273
 
205
- ### 3. Create `tsconfig.json`
206
-
207
- ```json
208
- {
209
- "$schema": "https://json.schemastore.org/tsconfig",
210
- "extends": "./tsconfig.base.json",
211
- "compilerOptions": {
212
- "composite": true,
213
- "rootDir": "./src",
214
- "outDir": "./dist"
215
- },
216
- "include": ["src/**/*"]
217
- }
218
- ```
274
+ ## Code Style
219
275
 
220
- ### 4. Create `tsconfig.base.json`
276
+ All style rules are **mandatory** — CI enforces them on every merge request.
221
277
 
222
- ```json
223
- {
224
- "$schema": "https://json.schemastore.org/tsconfig",
225
- "extends": "@xmachines/shared/tsconfig",
226
- "compilerOptions": {
227
- "skipLibCheck": true
228
- }
229
- }
230
- ```
278
+ ### Formatter — oxfmt
231
279
 
232
- If the package depends on other packages in this monorepo, add `references`:
280
+ oxfmt (Biome-based) is configured via `oxfmt.config.ts` at the root (extends `@xmachines/shared/oxfmt`).
233
281
 
234
- ```json
235
- {
236
- "extends": "@xmachines/shared/tsconfig",
237
- "compilerOptions": { "skipLibCheck": true },
238
- "references": [{ "path": "../play" }, { "path": "../play-actor" }]
239
- }
282
+ ```bash
283
+ npm run format # Format all files
284
+ npm run format:check # Check without writing (CI mode)
240
285
  ```
241
286
 
242
- ### 5. Register in root `tsconfig.json`
287
+ Key settings (from `packages/shared/config/oxfmt.config.ts`):
243
288
 
244
- Add an entry to the `references` array in the appropriate layer:
289
+ | Setting | Value |
290
+ | --------------- | ------------------------------------- |
291
+ | Print width | 100 characters |
292
+ | Indentation | Tabs (`useTabs: true`, `tabWidth: 4`) |
293
+ | Semicolons | Always (`semi: true`) |
294
+ | Quotes | Double (`singleQuote: false`) |
295
+ | Trailing commas | All |
296
+ | JSON / YAML | 2-space indent (override) |
245
297
 
246
- ```json
247
- {
248
- "references": [{ "path": "./packages/my-new-package" }]
249
- }
250
- ```
251
-
252
- ### 6. Register in root `tsconfig.test.json`
298
+ ### Linter — oxlint
253
299
 
254
- ```json
255
- {
256
- "references": [{ "path": "./packages/my-new-package/tsconfig.test.json" }]
257
- }
258
- ```
300
+ oxlint is configured via `oxlint.config.ts` at the root (extends `@xmachines/shared/oxlint`).
259
301
 
260
- ### 7. Create `vitest.config.ts`
261
-
262
- ```typescript
263
- import { defineXmVitestConfig } from "@xmachines/shared/vitest";
264
-
265
- export default defineXmVitestConfig(import.meta.url, {
266
- test: {
267
- environment: "node",
268
- include: ["test/**/*.spec.ts", "test/**/*.test.ts"],
269
- coverage: {
270
- provider: "v8",
271
- include: ["src/**/*.ts"],
272
- thresholds: {
273
- lines: 80,
274
- functions: 80,
275
- branches: 75,
276
- statements: 80,
277
- },
278
- },
279
- },
280
- });
302
+ ```bash
303
+ npm run lint # Lint all packages
304
+ npm run lint:fix # Auto-fix lint issues
281
305
  ```
282
306
 
283
- ### 8. Register in root `vitest.config.ts`
307
+ Active plugins: `typescript`, `unicorn`, `import`. Key rules:
284
308
 
285
- Add the package's `vitest.config.ts` to the `projects` array in the root `vitest.config.ts`.
309
+ | Rule | Severity |
310
+ | ---------------------------- | ------------------------------ |
311
+ | `typescript/no-explicit-any` | error |
312
+ | `import/no-cycle` | error |
313
+ | `typescript/no-unused-vars` | error (prefix unused with `_`) |
314
+ | `correctness` category | error |
315
+ | `suspicious` category | warn |
286
316
 
287
- ---
288
-
289
- ## Code Style
290
-
291
- ### Rules enforced
292
-
293
- **All rules below are mandatory and enforced in CI.**
317
+ ### Editor Config
294
318
 
295
- #### 1. `.js` extensions on all imports
296
-
297
- Even in TypeScript source files, imports must use `.js` extensions. This is required by Node.js ESM resolution:
298
-
299
- ```typescript
300
- // ✅ Correct
301
- import { foo } from "./bar.js";
302
- import { PlayEvent } from "@xmachines/play";
303
-
304
- // ❌ Wrong — will fail at runtime
305
- import { foo } from "./bar";
306
- ```
319
+ `.editorconfig` is present at the root and enforces:
307
320
 
308
- #### 2. ESM only no CommonJS
321
+ - Tabs for indentation in all source files
322
+ - 2-space indent for JSON/YAML
323
+ - LF line endings, UTF-8, insert final newline
309
324
 
310
- Every package has `"type": "module"` in its `package.json`. Do not use `require()`, `module.exports`, or `.cjs` files.
325
+ ### TypeScript Strict Mode
311
326
 
312
- #### 3. Strict TypeScript
313
-
314
- The base `tsconfig.json` enables the full strict suite plus additional checks:
327
+ All packages extend `@xmachines/shared/tsconfig` which enables full strict mode. Mandatory constraints:
315
328
 
316
329
  | Option | Value |
317
330
  | ---------------------------- | ------ |
@@ -324,161 +337,80 @@ The base `tsconfig.json` enables the full strict suite plus additional checks:
324
337
  | `verbatimModuleSyntax` | `true` |
325
338
  | `isolatedModules` | `true` |
326
339
 
327
- Use `import type` for type-only imports (required by `verbatimModuleSyntax`).
328
-
329
- #### 4. No `any`
330
-
331
- `typescript/no-explicit-any` is set to `"error"` in the shared oxlint config. Use `unknown` or appropriate generic types instead.
340
+ Use `unknown` with type guards instead of `any`. Prefix unused locals/parameters with `_` to suppress errors.
332
341
 
333
- ### Linting (oxlint)
342
+ ### Import Rules
334
343
 
335
- The project uses **oxlint** a Rust-based linter with TypeScript, unicorn, and import plugins.
344
+ 1. Always use `.js` extensions in imports, even for TypeScript source files:
336
345
 
337
- ```bash
338
- npm run lint # Lint all packages
339
- npm run lint:fix # Auto-fix lint issues across all packages
340
- ```
346
+ ```typescript
347
+ // Correct
348
+ import { PlayError } from "./errors.js";
341
349
 
342
- Root config: `oxlint.config.ts`
343
- Shared base: `packages/shared/config/oxlint.config.ts`
350
+ // Wrong — will not resolve at runtime with NodeNext module resolution
351
+ import { PlayError } from "./errors";
352
+ ```
344
353
 
345
- Enabled categories: `correctness: error`, `suspicious: warn`, `perf: warn`. Import cycle detection (`import/no-cycle`) is set to `"error"`.
354
+ 2. Use `import type` for type-only imports (required by `verbatimModuleSyntax`):
346
355
 
347
- ### Formatting (oxfmt)
348
-
349
- The project uses **oxfmt** — an opinionated formatter.
350
-
351
- ```bash
352
- npm run format # Format all files in place
353
- npm run format:check # Check formatting without writing (CI mode)
354
- ```
356
+ ```typescript
357
+ import type { RouteNode, RouteTree } from "../src/types.js";
358
+ ```
355
359
 
356
- Root config: `oxfmt.config.ts`
357
- Shared base: `packages/shared/config/oxfmt.config.ts`
358
-
359
- Key settings (from shared config):
360
-
361
- | Setting | Value |
362
- | --------------- | ------------------------- |
363
- | Print width | 100 |
364
- | Indentation | Tabs (width 4) |
365
- | Semicolons | `true` |
366
- | Quotes | Double |
367
- | Trailing commas | All |
368
- | JSON/YAML files | 2-space indent (override) |
369
-
370
- ### EditorConfig
371
-
372
- An `.editorconfig` at the project root ensures consistent whitespace in editors:
373
-
374
- - All files: tabs (4-wide), LF line endings, insert final newline
375
- - JSON/YAML: spaces (2-wide)
376
- - Markdown: trailing whitespace preserved
360
+ 3. Import order: Node.js built-ins (`node:` prefix) → external packages → internal `@xmachines/*` packages → relative imports
377
361
 
378
362
  ---
379
363
 
380
- ## Testing
381
-
382
- ### Test framework
383
-
384
- All packages use **Vitest 4.x** with **v8 coverage**.
385
-
386
- ### Running tests
364
+ ## Branch Conventions
387
365
 
388
- | Command | Description |
389
- | -------------------------- | ------------------------------------------------ |
390
- | `npm test` | Run all tests (node environment) |
391
- | `npm run test:watch` | Interactive watch mode |
392
- | `npm run test:ui` | Vitest browser UI for visual debugging |
393
- | `npm run test:browser` | Run browser-mode tests (Playwright/Chromium) |
394
- | `npm run test:coverage` | Run with coverage, output text/HTML/JSON-summary |
395
- | `npm run coverage:report` | Coverage with HTML report |
396
- | `npm run coverage:summary` | Coverage with JSON summary |
397
- | `npm run test:build` | Type-check all test files (no emit) |
366
+ Use a `<type>/` prefix that matches the conventional commit type for the work being done:
398
367
 
399
- To run tests for a single package in isolation:
400
-
401
- ```bash
402
- npm test -w packages/play-actor
403
368
  ```
404
-
405
- ### Test file conventions
406
-
407
- - Place test files in `test/` within each package
408
- - Use `.spec.ts` or `.test.ts` extensions
409
- - Both are supported; `.spec.ts` is the conventional choice for unit tests
410
-
411
- ### Coverage thresholds
412
-
413
- Root-level (regression gate for the full monorepo):
414
-
415
- | Type | Threshold |
416
- | ---------- | --------- |
417
- | Lines | 80% |
418
- | Functions | 80% |
419
- | Branches | 75% |
420
- | Statements | 80% |
421
-
422
- Core packages enforce higher per-package thresholds in their own `vitest.config.ts`. For example, `play-actor` requires 90% lines/functions/statements and 85% branches.
423
-
424
- ### Browser tests
425
-
426
- Browser tests use Vitest's Playwright integration (Chromium). They run separately from node tests:
427
-
428
- ```bash
429
- npm run test:browser
369
+ feat/vue-router-adapter
370
+ fix/signal-watcher-cleanup
371
+ docs/play-actor-jsdoc
372
+ chore/update-vitest-4
373
+ refactor/route-map-extraction
430
374
  ```
431
375
 
432
- Browser test configs are named `vitest.browser.config.ts` inside each package. Not all packages have browser tests — add them only when the code has meaningful browser-specific behavior.
433
-
434
- ### Shared test setup
435
-
436
- The [`@xmachines/shared/vitest`](../api/@xmachines/shared/vitest/README.md) helper ([`defineXmVitestConfig`](../api/@xmachines/shared/vitest/functions/defineXmVitestConfig.md)) automatically:
376
+ Release branches are managed by the project maintainers:
437
377
 
438
- - Configures `@xmachines/*` path aliases so tests resolve to source files
439
- - Injects the shared setup file (`vitest.setup.ts`) for global test utilities
440
- - Injects the node setup file (`vitest.node.setup.ts`) for non-browser packages
378
+ | Branch | Purpose |
379
+ | -------- | ------------------------- |
380
+ | `main` | Stable releases |
381
+ | `beta` | Pre-release beta channel |
382
+ | `pre/rc` | Release candidate channel |
441
383
 
442
- Use [`defineXmVitestConfig`](../api/@xmachines/shared/vitest/functions/defineXmVitestConfig.md) in every package's `vitest.config.ts` instead of bare `defineConfig`.
384
+ **Do not** manually version packages or create release branches — releases are automated via semantic-release triggered by CI.
443
385
 
444
386
  ---
445
387
 
446
- ## Commit Conventions
388
+ ## PR Process
447
389
 
448
- This project uses [Conventional Commits](https://www.conventionalcommits.org/). Commit messages are parsed by `semantic-release` to determine version bumps and changelog entries.
390
+ ### Commit Messages
449
391
 
450
- ### Format
392
+ This project uses **Conventional Commits** — changelogs and version bumps are generated automatically from commit history.
451
393
 
452
394
  ```
453
- <type>(<scope>): <description>
395
+ <type>[(<scope>)][!]: <short description>
454
396
 
455
397
  [optional body]
456
398
 
457
399
  [optional footer]
458
400
  ```
459
401
 
460
- ### Types
402
+ | Type | Triggers version bump | When to use |
403
+ | ---------- | ------------------------- | ---------------------------------------- |
404
+ | `feat` | Minor | New user-facing feature |
405
+ | `fix` | Patch | Bug fix |
406
+ | `docs` | No bump | Documentation only |
407
+ | `refactor` | No bump | Code restructure without behavior change |
408
+ | `test` | No bump | Adding or updating tests |
409
+ | `chore` | No bump | Build, tooling, or dependency changes |
410
+ | `perf` | No bump (unless breaking) | Performance improvements |
411
+ | `ci` | No bump | CI/CD pipeline changes |
461
412
 
462
- | Type | Triggers | When to use |
463
- | ---------- | ------------------------- | ------------------------------------------ |
464
- | `feat` | Minor bump | New user-facing feature |
465
- | `fix` | Patch bump | Bug fix |
466
- | `docs` | No bump | Documentation only |
467
- | `chore` | No bump | Build scripts, tooling, dependencies |
468
- | `refactor` | No bump | Code restructuring without behavior change |
469
- | `test` | No bump | Adding or updating tests |
470
- | `perf` | No bump (unless breaking) | Performance improvement |
471
- | `ci` | No bump | CI configuration changes |
472
-
473
- A `BREAKING CHANGE:` footer or `!` after the type triggers a major version bump:
474
-
475
- ```
476
- feat!: drop Node 20 support
477
-
478
- BREAKING CHANGE: Minimum Node version is now 22.
479
- ```
480
-
481
- ### Scope (optional)
413
+ Breaking changes: append `!` after the type (`feat!:`) or add `BREAKING CHANGE:` in the footer.
482
414
 
483
415
  Use the package short-name as scope when the change is isolated to one package:
484
416
 
@@ -487,131 +419,46 @@ fix(play-actor): correct signal cleanup on dispose
487
419
  feat(play-react): add PlayRenderer suspense boundary
488
420
  ```
489
421
 
490
- ---
422
+ ### Before Submitting
491
423
 
492
- ## Documentation
424
+ 1. **Read the relevant RFC** in [`packages/docs/rfc/`](../packages/docs/rfc/) — ensure your change conforms to the spec
425
+ 2. **Run the full check suite** from the repo root:
493
426
 
494
- API documentation is generated from TypeScript source using **TypeDoc**.
427
+ ```bash
428
+ npm run build
429
+ npm test
430
+ npm run lint
431
+ npm run format:check
432
+ ```
495
433
 
496
- ```bash
497
- npm run docs
498
- ```
434
+ 3. **Write tests** — new code must meet coverage thresholds (80% lines/functions/statements and 75% branches at the monorepo level; core packages enforce higher per-package thresholds)
435
+ 4. **Add JSDoc** — all new public exports require JSDoc with `@param`, `@returns`, and `@see` RFC links
436
+ 5. **Never edit `packages/docs/api/`** — API docs are auto-generated; edit source JSDoc and regenerate with `npm run docs`
499
437
 
500
- This runs the full build, generates API docs into `packages/docs/api/`, then formats the output.
438
+ ### Merge Request Checklist
501
439
 
502
- **Important:** `packages/docs/api/` is auto-generated and committed to git. **Never edit files inside it directly.** Always regenerate via `npm run docs`.
440
+ - [ ] Branch is up to date with `main`
441
+ - [ ] All tests pass (`npm test`)
442
+ - [ ] Lint passes (`npm run lint`)
443
+ - [ ] Formatting is correct (`npm run format:check`)
444
+ - [ ] Build succeeds (`npm run build`)
445
+ - [ ] New code has tests at or above coverage thresholds
446
+ - [ ] All new public exports have JSDoc
447
+ - [ ] Conventional commit format used on all commits
448
+ - [ ] RFC read and implementation conforms to spec
503
449
 
504
- ### RFC links in JSDoc
450
+ ### CI Pipeline
505
451
 
506
- RFC files live at `packages/docs/rfc/`. Use relative links in `@see` tags:
452
+ The GitLab CI pipeline runs automatically on merge requests, pushes to `main`, and git tags.
507
453
 
508
- ```typescript
509
- /**
510
- * @see `Play RFC`
511
- */
512
- ```
513
-
514
- TypeDoc's custom plugin (`typedoc.config.mjs`) handles rewriting these links in the generated output.
454
+ | Job | Command | Artifacts |
455
+ | ------------------ | ------------------------------------- | -------------------------------------- |
456
+ | Build | `npm run build` | — |
457
+ | Test with coverage | `vitest run --coverage` | JUnit XML, Cobertura coverage report |
458
+ | Lint | `oxlint .` | — |
459
+ | Audit | `npm audit --audit-level=high` | — |
460
+ | Semantic release | (automated on `main`/`beta`/`pre/rc`) | CHANGELOG, npm publish, GitLab release |
515
461
 
516
462
  ---
517
463
 
518
- ## Patches
519
-
520
- The `patches/` directory contains `patch-package` patches applied automatically during `npm ci` and `npm install` (via the `postinstall` script).
521
-
522
- Current patches are for `@json-render` packages. Do not remove or manually modify patch files — they are required for the build to succeed.
523
-
524
- To create a new patch after modifying a file in `node_modules/`:
525
-
526
- ```bash
527
- npx patch-package <package-name>
528
- ```
529
-
530
- ---
531
-
532
- ## Release Process
533
-
534
- Releases are fully automated via **semantic-release** running in GitLab CI. No manual version bumping or tagging is required.
535
-
536
- ### How releases work
537
-
538
- 1. Commits merged to `main` are analyzed by `@semantic-release/commit-analyzer`
539
- 2. If releasable commits are present, semantic-release:
540
- - Determines the next version from commit types
541
- - Updates all workspace `package.json` versions via `scripts/set-workspace-versions.mjs`
542
- - Builds all packages and regenerates API docs
543
- - Publishes all publishable packages to npm
544
- - Creates a GitLab release with tarball artifacts
545
- - Commits `CHANGELOG.md`, updated `package.json` files, and generated docs back to the branch
546
-
547
- ### Release branches
548
-
549
- | Branch | Channel | Pre-release tag |
550
- | -------- | ------- | --------------- |
551
- | `main` | stable | — |
552
- | `beta` | beta | `beta` |
553
- | `pre/rc` | pre/rc | `rc` |
554
-
555
- ### Smoke testing before release
556
-
557
- The `release-pack-smoke` CI job validates that packed tarballs install correctly:
558
-
559
- ```bash
560
- npm run build
561
- node scripts/release-pack-smoke.mjs
562
- ```
563
-
564
- This job runs automatically on `main` pushes and tags but can be triggered manually on other branches.
565
-
566
- ### Published packages
567
-
568
- All packages listed in `.releaserc.json` with `npmPublish: true` (the default) are published to npm under the `@xmachines/` scope. Example packages (`examples/demo`) are packed for the GitLab release but not published to npm.
569
-
570
- ---
571
-
572
- ## CI Pipeline
573
-
574
- The GitLab CI pipeline (`.gitlab-ci.yml`) runs on:
575
-
576
- - Every push to `main`
577
- - Every merge request
578
- - Every git tag
579
-
580
- ### Pipeline stages
581
-
582
- | Job | Description |
583
- | -------------------- | ----------------------------------------------------------------------------- |
584
- | `node-build` | Lints, builds, and runs `test:coverage`; reports JUnit and Cobertura coverage |
585
- | `semantic-release` | Automated release on `main`, `beta`, and `pre/rc` branches |
586
- | `release-pack-smoke` | Validates packed tarballs install correctly |
587
-
588
- The pipeline uses the `to-be-continuous/node` component and `to-be-continuous/semantic-release` component from the GitLab CI component catalog.
589
-
590
- **Coverage gate:** The CI reports coverage in Cobertura format. The regex `/All files[^|]*\|[^|]*\s+([\d\.]+)/` extracts the aggregate coverage percentage.
591
-
592
- ---
593
-
594
- ## Common Setup Issues
595
-
596
- **Tests fail with `Cannot find module` errors**
597
- : Run `npm run build` before running tests. Some packages need their `dist/` present even in development. Alternatively, ensure [`@xmachines/shared/vite-aliases`](../api/@xmachines/shared/vite-aliases/README.md) aliases are configured in your `vitest.config.ts` — use [`defineXmVitestConfig`](../api/@xmachines/shared/vitest/functions/defineXmVitestConfig.md) from [`@xmachines/shared/vitest`](../api/@xmachines/shared/vitest/README.md) to get them automatically.
598
-
599
- **TypeScript errors about missing types after adding a dependency**
600
- : Run `npm ci` to ensure all types are installed. If adding a workspace-local dependency, also add the correct `references` entry to the package's `tsconfig.base.json`.
601
-
602
- **`patch-package` errors during install**
603
- : The patches in `patches/` are version-specific. If you update a `@json-render` package, the patches may need to be regenerated with `npx patch-package <pkg>`.
604
-
605
- **Lint errors on import extensions**
606
- : All imports must end with `.js`. This applies to relative imports even for `.ts` source files. Your editor's auto-import may omit the extension — fix it manually or configure your editor to add it automatically.
607
-
608
- **Build is slow after a `git clean`**
609
- : TypeScript incremental builds use `.tsbuildinfo` files. After a full clean these are gone and the initial build will be slower. This is expected.
610
-
611
- ---
612
-
613
- ## Related Documentation
614
-
615
- - [Architecture](../guides/architecture.md) — System design, component diagram, data flow
616
- - [Configuration](configuration.md) — Environment variables and config files
617
- - [RFC docs](../rfc/) — Canonical specifications for each protocol
464
+ _See [ARCHITECTURE.md](ARCHITECTURE.md) for the package layering and data flow details, and [CONFIGURATION.md](CONFIGURATION.md) for tooling configuration reference._