one 1.1.309 → 1.1.311

Sign up to get free protection for your applications and to get access to all the features.
Files changed (401) hide show
  1. package/dist/cjs/Root.cjs +213 -0
  2. package/dist/cjs/Root.cjs.map +6 -0
  3. package/dist/cjs/Root.native.js +2 -2
  4. package/dist/cjs/Root.native.js.map +2 -2
  5. package/dist/cjs/{Route.js → Route.cjs} +34 -19
  6. package/dist/cjs/{cleanUrl.js → cleanUrl.cjs} +27 -18
  7. package/dist/cjs/cli/label-process.cjs +31 -0
  8. package/dist/cjs/cli/{main.js → main.cjs} +28 -16
  9. package/dist/cjs/cli/{prebuild.js → prebuild.cjs} +25 -15
  10. package/dist/cjs/cli/run.cjs +70 -0
  11. package/dist/cjs/cli/{runAndroid.js → runAndroid.cjs} +25 -15
  12. package/dist/cjs/cli/{runIos.js → runIos.cjs} +25 -15
  13. package/dist/cjs/cli.cjs +258 -0
  14. package/dist/cjs/clientLoaderResolver.cjs +35 -0
  15. package/dist/cjs/config.cjs +32 -0
  16. package/dist/cjs/constants.cjs +30 -0
  17. package/dist/cjs/{createApp.js → createApp.cjs} +33 -17
  18. package/dist/cjs/createApp.native.cjs +38 -0
  19. package/dist/cjs/createApp.native.cjs.map +6 -0
  20. package/dist/cjs/{createHandleRequest.js → createHandleRequest.cjs} +61 -49
  21. package/dist/cjs/createHandleRequest.cjs.map +6 -0
  22. package/dist/cjs/createHandleRequest.native.js +1 -0
  23. package/dist/cjs/createHandleRequest.native.js.map +2 -2
  24. package/dist/cjs/createRoute.cjs +42 -0
  25. package/dist/cjs/fallbackViews/{Sitemap.js → Sitemap.cjs} +35 -16
  26. package/dist/cjs/fallbackViews/{Unmatched.js → Unmatched.cjs} +32 -17
  27. package/dist/cjs/fork/NavigationContainer.cjs +105 -0
  28. package/dist/cjs/fork/NavigationContainer.native.cjs +103 -0
  29. package/dist/cjs/fork/NavigationContainer.native.cjs.map +6 -0
  30. package/dist/cjs/fork/createMemoryHistory.cjs +136 -0
  31. package/dist/cjs/fork/{extractPathFromURL.js → extractPathFromURL.cjs} +30 -21
  32. package/dist/cjs/fork/findFocusedRoute.cjs +30 -0
  33. package/dist/cjs/fork/{getPathFromState.js → getPathFromState.cjs} +120 -113
  34. package/dist/cjs/fork/getStateFromPath.cjs +366 -0
  35. package/dist/cjs/fork/useLinking.cjs +215 -0
  36. package/dist/cjs/fork/useLinking.native.cjs +126 -0
  37. package/dist/cjs/fork/useLinking.native.cjs.map +6 -0
  38. package/dist/cjs/fork/validatePathConfig.cjs +44 -0
  39. package/dist/cjs/{getLinkingConfig.js → getLinkingConfig.cjs} +21 -15
  40. package/dist/cjs/{getReactNavigationConfig.js → getReactNavigationConfig.cjs} +33 -32
  41. package/dist/cjs/getRoutes.cjs +276 -0
  42. package/dist/cjs/getURL.cjs +29 -0
  43. package/dist/cjs/getURL.native.cjs +48 -0
  44. package/dist/cjs/getURL.native.cjs.map +6 -0
  45. package/dist/cjs/head/Head.android.cjs +28 -0
  46. package/dist/cjs/head/Head.android.cjs.map +6 -0
  47. package/dist/cjs/head/Head.cjs +30 -0
  48. package/dist/cjs/head/Head.ios.cjs +210 -0
  49. package/dist/cjs/head/Head.ios.cjs.map +6 -0
  50. package/dist/cjs/head/HeadModule.cjs +27 -0
  51. package/dist/cjs/head/index.cjs +18 -0
  52. package/dist/cjs/head/types.cjs +16 -0
  53. package/dist/cjs/head/url.cjs +50 -0
  54. package/dist/cjs/{hooks.js → hooks.cjs} +52 -40
  55. package/dist/cjs/{imperative-api.js → imperative-api.cjs} +26 -19
  56. package/dist/cjs/import-mode/index.android.cjs +26 -0
  57. package/dist/cjs/import-mode/index.android.cjs.map +6 -0
  58. package/dist/cjs/import-mode/index.cjs +26 -0
  59. package/dist/cjs/import-mode/index.ios.cjs +26 -0
  60. package/dist/cjs/import-mode/index.ios.cjs.map +6 -0
  61. package/dist/cjs/import-mode/index.native.cjs +26 -0
  62. package/dist/cjs/import-mode/index.native.cjs.map +6 -0
  63. package/dist/cjs/import-mode/index.web.cjs +26 -0
  64. package/dist/cjs/{index.js → index.cjs} +50 -14
  65. package/dist/cjs/interfaces/router.cjs +27 -0
  66. package/dist/cjs/layouts/Drawer.cjs +31 -0
  67. package/dist/cjs/layouts/Stack.cjs +31 -0
  68. package/dist/cjs/layouts/Tabs.cjs +64 -0
  69. package/dist/cjs/layouts/withLayoutContext.cjs +91 -0
  70. package/dist/cjs/link/Link.cjs +120 -0
  71. package/dist/cjs/link/Redirect.cjs +39 -0
  72. package/dist/cjs/link/href.cjs +58 -0
  73. package/dist/cjs/link/linking.cjs +89 -0
  74. package/dist/cjs/link/path.cjs +69 -0
  75. package/dist/cjs/link/useLinkTo.cjs +54 -0
  76. package/dist/cjs/link/useLoadedNavigation.cjs +60 -0
  77. package/dist/cjs/{matchers.js → matchers.cjs} +16 -11
  78. package/dist/cjs/platform.cjs +26 -0
  79. package/dist/cjs/polyfills-mobile.cjs +33 -0
  80. package/dist/cjs/polyfills-server.cjs +25 -0
  81. package/dist/cjs/render.cjs +47 -0
  82. package/dist/cjs/render.native.cjs +28 -0
  83. package/dist/cjs/render.native.cjs.map +6 -0
  84. package/dist/cjs/router/RouterStore.cjs +16 -0
  85. package/dist/cjs/router/constants.cjs +26 -0
  86. package/dist/cjs/router/{getNormalizedStatePath.js → getNormalizedStatePath.cjs} +25 -23
  87. package/dist/cjs/router/lastAction.cjs +31 -0
  88. package/dist/cjs/router/{router.js → router.cjs} +104 -78
  89. package/dist/cjs/router/serverLocationContext.cjs +27 -0
  90. package/dist/cjs/router/{useInitializeOneRouter.js → useInitializeOneRouter.cjs} +26 -16
  91. package/dist/cjs/serve.cjs +185 -0
  92. package/dist/cjs/server/{createRoutesManifest.js → createRoutesManifest.cjs} +22 -16
  93. package/dist/cjs/server/{getServerManifest.js → getServerManifest.cjs} +58 -31
  94. package/dist/cjs/{server-render.js → server-render.cjs} +28 -17
  95. package/dist/cjs/sortRoutes.cjs +62 -0
  96. package/dist/cjs/typed-routes/generateRouteTypes.cjs +48 -0
  97. package/dist/cjs/typed-routes/{getTypedRoutesDeclarationFile.js → getTypedRoutesDeclarationFile.cjs} +37 -40
  98. package/dist/cjs/types.cjs +16 -0
  99. package/dist/cjs/{useFocusEffect.js → useFocusEffect.cjs} +33 -24
  100. package/dist/cjs/useLoader.cjs +114 -0
  101. package/dist/cjs/useNavigation.cjs +68 -0
  102. package/dist/cjs/useScreens.cjs +233 -0
  103. package/dist/cjs/{useViteRoutes.js → useViteRoutes.cjs} +36 -24
  104. package/dist/cjs/utils/assertIsReady.cjs +28 -0
  105. package/dist/cjs/utils/dynamicImport.cjs +27 -0
  106. package/dist/cjs/utils/existsAsync.cjs +33 -0
  107. package/dist/cjs/utils/getPageExport.cjs +32 -0
  108. package/dist/cjs/utils/{globDir.js → globDir.cjs} +23 -15
  109. package/dist/cjs/utils/{hashString.js → hashString.cjs} +22 -14
  110. package/dist/cjs/utils/isResponse.cjs +28 -0
  111. package/dist/cjs/utils/isStatus.cjs +28 -0
  112. package/dist/cjs/utils/promiseWithResolvers.cjs +37 -0
  113. package/dist/cjs/utils/rand.cjs +26 -0
  114. package/dist/cjs/utils/redirect.cjs +34 -0
  115. package/dist/cjs/utils/removeSearch.cjs +28 -0
  116. package/dist/cjs/utils/removeUndefined.cjs +30 -0
  117. package/dist/cjs/utils/{url.js → url.cjs} +16 -11
  118. package/dist/cjs/utils/weakKey.cjs +30 -0
  119. package/dist/cjs/utils/weakMemo.cjs +34 -0
  120. package/dist/cjs/views/EmptyRoute.cjs +30 -0
  121. package/dist/cjs/views/{ErrorBoundary.js → ErrorBoundary.cjs} +30 -16
  122. package/dist/cjs/views/LoadProgressBar.cjs +90 -0
  123. package/dist/cjs/views/Navigator.cjs +149 -0
  124. package/dist/cjs/views/{PreloadLinks.js → PreloadLinks.cjs} +20 -13
  125. package/dist/cjs/views/PreloadLinks.native.cjs +28 -0
  126. package/dist/cjs/views/PreloadLinks.native.cjs.map +6 -0
  127. package/dist/cjs/views/{RootErrorBoundary.js → RootErrorBoundary.cjs} +28 -16
  128. package/dist/cjs/views/Screen.cjs +39 -0
  129. package/dist/cjs/views/ScrollRestoration.cjs +74 -0
  130. package/dist/cjs/views/Try.cjs +68 -0
  131. package/dist/cjs/vite/build.cjs +425 -0
  132. package/dist/cjs/vite/{clientTreeShakePlugin.js → clientTreeShakePlugin.cjs} +53 -35
  133. package/dist/cjs/vite/constants.cjs +28 -0
  134. package/dist/cjs/vite/{createFileSystemRouter.js → createFileSystemRouter.cjs} +117 -84
  135. package/dist/cjs/vite/{customNodeExternals.js → customNodeExternals.cjs} +32 -20
  136. package/dist/cjs/vite/ensureTsConfig.cjs +68 -0
  137. package/dist/cjs/vite/findDepsToOptimize.cjs +74 -0
  138. package/dist/cjs/vite/{fixDependenciesPlugin.js → fixDependenciesPlugin.cjs} +17 -12
  139. package/dist/cjs/vite/generateTypesForRoutes.cjs +45 -0
  140. package/dist/cjs/vite/{getManifest.js → getManifest.cjs} +18 -12
  141. package/dist/cjs/vite/{headers.js → headers.cjs} +19 -14
  142. package/dist/cjs/vite/headers.native.cjs +32 -0
  143. package/dist/cjs/vite/headers.native.cjs.map +6 -0
  144. package/dist/cjs/vite/{loadEnv.js → loadEnv.cjs} +27 -16
  145. package/dist/cjs/vite/makePluginWebOnly.cjs +31 -0
  146. package/dist/cjs/vite/one.cjs +256 -0
  147. package/dist/cjs/vite/{removeReactNativeWebAnimatedPlugin.js → removeReactNativeWebAnimatedPlugin.cjs} +32 -25
  148. package/dist/cjs/vite/replaceLoader.cjs +37 -0
  149. package/dist/cjs/vite/resolveAPIRequest.cjs +90 -0
  150. package/dist/cjs/vite/server.cjs +13 -0
  151. package/dist/cjs/vite/types.cjs +16 -0
  152. package/dist/cjs/vite/{virtualEntryPlugin.js → virtualEntryPlugin.cjs} +28 -20
  153. package/dist/cjs/vite/{vitePluginSsrCss.js → vitePluginSsrCss.cjs} +56 -50
  154. package/dist/cjs/vite.cjs +40 -0
  155. package/dist/cjs/zero/getQueryKey.cjs +29 -0
  156. package/dist/cjs/zero/isZeroQuery.cjs +28 -0
  157. package/dist/cjs/zero/resolveQuery.cjs +41 -0
  158. package/dist/cjs/zero/{subscribeToQuery.js → subscribeToQuery.cjs} +16 -11
  159. package/dist/cjs/zero/types.cjs +16 -0
  160. package/dist/cjs/zero/useQuery.cjs +58 -0
  161. package/dist/cjs/zero/{useQueryZero.js → useQueryZero.cjs} +21 -15
  162. package/dist/cjs/zero.cjs +30 -0
  163. package/dist/esm/Root.js +2 -1
  164. package/dist/esm/Root.js.map +1 -1
  165. package/dist/esm/Root.mjs +2 -1
  166. package/dist/esm/Root.mjs.map +1 -1
  167. package/dist/esm/Root.native.js +2 -1
  168. package/dist/esm/Root.native.js.map +2 -2
  169. package/dist/esm/createHandleRequest.js +1 -0
  170. package/dist/esm/createHandleRequest.js.map +1 -1
  171. package/dist/esm/createHandleRequest.mjs +1 -0
  172. package/dist/esm/createHandleRequest.mjs.map +1 -1
  173. package/dist/esm/createHandleRequest.native.js +1 -0
  174. package/dist/esm/createHandleRequest.native.js.map +2 -2
  175. package/dist/esm/getURL.js +1 -1
  176. package/dist/esm/getURL.mjs +1 -1
  177. package/package.json +10 -10
  178. package/src/Root.tsx +2 -1
  179. package/src/createHandleRequest.ts +5 -0
  180. package/src/getURL.ts +1 -1
  181. package/types/Root.d.ts.map +1 -1
  182. package/types/createHandleRequest.d.ts.map +1 -1
  183. package/dist/cjs/Root.js +0 -182
  184. package/dist/cjs/Root.js.map +0 -6
  185. package/dist/cjs/cli/label-process.js +0 -25
  186. package/dist/cjs/cli/run.js +0 -52
  187. package/dist/cjs/cli.js +0 -209
  188. package/dist/cjs/clientLoaderResolver.js +0 -32
  189. package/dist/cjs/config.js +0 -27
  190. package/dist/cjs/constants.js +0 -23
  191. package/dist/cjs/createHandleRequest.js.map +0 -6
  192. package/dist/cjs/createRoute.js +0 -37
  193. package/dist/cjs/fork/NavigationContainer.js +0 -85
  194. package/dist/cjs/fork/createMemoryHistory.js +0 -100
  195. package/dist/cjs/fork/findFocusedRoute.js +0 -26
  196. package/dist/cjs/fork/getStateFromPath.js +0 -381
  197. package/dist/cjs/fork/useLinking.js +0 -182
  198. package/dist/cjs/fork/validatePathConfig.js +0 -46
  199. package/dist/cjs/getRoutes.js +0 -294
  200. package/dist/cjs/getURL.js +0 -24
  201. package/dist/cjs/head/Head.js +0 -23
  202. package/dist/cjs/head/HeadModule.js +0 -22
  203. package/dist/cjs/head/index.js +0 -15
  204. package/dist/cjs/head/types.js +0 -14
  205. package/dist/cjs/head/url.js +0 -52
  206. package/dist/cjs/import-mode/index.js +0 -21
  207. package/dist/cjs/import-mode/index.web.js +0 -21
  208. package/dist/cjs/interfaces/router.js +0 -23
  209. package/dist/cjs/layouts/Drawer.js +0 -24
  210. package/dist/cjs/layouts/Stack.js +0 -24
  211. package/dist/cjs/layouts/Tabs.js +0 -52
  212. package/dist/cjs/layouts/withLayoutContext.js +0 -77
  213. package/dist/cjs/link/Link.js +0 -98
  214. package/dist/cjs/link/Redirect.js +0 -31
  215. package/dist/cjs/link/href.js +0 -50
  216. package/dist/cjs/link/linking.js +0 -82
  217. package/dist/cjs/link/path.js +0 -65
  218. package/dist/cjs/link/useLinkTo.js +0 -42
  219. package/dist/cjs/link/useLoadedNavigation.js +0 -50
  220. package/dist/cjs/platform.js +0 -21
  221. package/dist/cjs/polyfills-mobile.js +0 -26
  222. package/dist/cjs/polyfills-server.js +0 -23
  223. package/dist/cjs/render.js +0 -44
  224. package/dist/cjs/router/RouterStore.js +0 -14
  225. package/dist/cjs/router/constants.js +0 -21
  226. package/dist/cjs/router/lastAction.js +0 -25
  227. package/dist/cjs/router/serverLocationContext.js +0 -22
  228. package/dist/cjs/serve.js +0 -175
  229. package/dist/cjs/sortRoutes.js +0 -64
  230. package/dist/cjs/typed-routes/generateRouteTypes.js +0 -33
  231. package/dist/cjs/types.js +0 -14
  232. package/dist/cjs/useLoader.js +0 -97
  233. package/dist/cjs/useNavigation.js +0 -60
  234. package/dist/cjs/useScreens.js +0 -176
  235. package/dist/cjs/utils/assertIsReady.js +0 -26
  236. package/dist/cjs/utils/dynamicImport.js +0 -24
  237. package/dist/cjs/utils/existsAsync.js +0 -28
  238. package/dist/cjs/utils/getPageExport.js +0 -27
  239. package/dist/cjs/utils/isResponse.js +0 -23
  240. package/dist/cjs/utils/isStatus.js +0 -23
  241. package/dist/cjs/utils/promiseWithResolvers.js +0 -26
  242. package/dist/cjs/utils/rand.js +0 -21
  243. package/dist/cjs/utils/redirect.js +0 -28
  244. package/dist/cjs/utils/removeSearch.js +0 -23
  245. package/dist/cjs/utils/removeUndefined.js +0 -26
  246. package/dist/cjs/utils/weakKey.js +0 -24
  247. package/dist/cjs/utils/weakMemo.js +0 -30
  248. package/dist/cjs/views/EmptyRoute.js +0 -25
  249. package/dist/cjs/views/LoadProgressBar.js +0 -83
  250. package/dist/cjs/views/Navigator.js +0 -101
  251. package/dist/cjs/views/Screen.js +0 -29
  252. package/dist/cjs/views/ScrollRestoration.js +0 -70
  253. package/dist/cjs/views/Try.js +0 -44
  254. package/dist/cjs/vite/build.js +0 -376
  255. package/dist/cjs/vite/constants.js +0 -22
  256. package/dist/cjs/vite/ensureTsConfig.js +0 -66
  257. package/dist/cjs/vite/findDepsToOptimize.js +0 -66
  258. package/dist/cjs/vite/generateTypesForRoutes.js +0 -36
  259. package/dist/cjs/vite/makePluginWebOnly.js +0 -27
  260. package/dist/cjs/vite/one.js +0 -255
  261. package/dist/cjs/vite/replaceLoader.js +0 -34
  262. package/dist/cjs/vite/resolveAPIRequest.js +0 -71
  263. package/dist/cjs/vite/server.js +0 -16
  264. package/dist/cjs/vite/types.js +0 -14
  265. package/dist/cjs/vite.js +0 -28
  266. package/dist/cjs/zero/getQueryKey.js +0 -24
  267. package/dist/cjs/zero/isZeroQuery.js +0 -23
  268. package/dist/cjs/zero/resolveQuery.js +0 -38
  269. package/dist/cjs/zero/types.js +0 -14
  270. package/dist/cjs/zero/useQuery.js +0 -47
  271. package/dist/cjs/zero.js +0 -23
  272. /package/dist/cjs/{Route.js.map → Route.cjs.map} +0 -0
  273. /package/dist/cjs/{cleanUrl.js.map → cleanUrl.cjs.map} +0 -0
  274. /package/dist/cjs/cli/{label-process.js.map → label-process.cjs.map} +0 -0
  275. /package/dist/cjs/cli/{main.js.map → main.cjs.map} +0 -0
  276. /package/dist/cjs/cli/{prebuild.js.map → prebuild.cjs.map} +0 -0
  277. /package/dist/cjs/cli/{run.js.map → run.cjs.map} +0 -0
  278. /package/dist/cjs/cli/{runAndroid.js.map → runAndroid.cjs.map} +0 -0
  279. /package/dist/cjs/cli/{runIos.js.map → runIos.cjs.map} +0 -0
  280. /package/dist/cjs/{cli.js.map → cli.cjs.map} +0 -0
  281. /package/dist/cjs/{clientLoaderResolver.js.map → clientLoaderResolver.cjs.map} +0 -0
  282. /package/dist/cjs/{config.js.map → config.cjs.map} +0 -0
  283. /package/dist/cjs/{constants.js.map → constants.cjs.map} +0 -0
  284. /package/dist/cjs/{createApp.js.map → createApp.cjs.map} +0 -0
  285. /package/dist/cjs/{createRoute.js.map → createRoute.cjs.map} +0 -0
  286. /package/dist/cjs/fallbackViews/{Sitemap.js.map → Sitemap.cjs.map} +0 -0
  287. /package/dist/cjs/fallbackViews/{Unmatched.js.map → Unmatched.cjs.map} +0 -0
  288. /package/dist/cjs/fork/{NavigationContainer.js.map → NavigationContainer.cjs.map} +0 -0
  289. /package/dist/cjs/fork/{createMemoryHistory.js.map → createMemoryHistory.cjs.map} +0 -0
  290. /package/dist/cjs/fork/{extractPathFromURL.js.map → extractPathFromURL.cjs.map} +0 -0
  291. /package/dist/cjs/fork/{findFocusedRoute.js.map → findFocusedRoute.cjs.map} +0 -0
  292. /package/dist/cjs/fork/{getPathFromState.js.map → getPathFromState.cjs.map} +0 -0
  293. /package/dist/cjs/fork/{getStateFromPath.js.map → getStateFromPath.cjs.map} +0 -0
  294. /package/dist/cjs/fork/{useLinking.js.map → useLinking.cjs.map} +0 -0
  295. /package/dist/cjs/fork/{validatePathConfig.js.map → validatePathConfig.cjs.map} +0 -0
  296. /package/dist/cjs/{getLinkingConfig.js.map → getLinkingConfig.cjs.map} +0 -0
  297. /package/dist/cjs/{getReactNavigationConfig.js.map → getReactNavigationConfig.cjs.map} +0 -0
  298. /package/dist/cjs/{getRoutes.js.map → getRoutes.cjs.map} +0 -0
  299. /package/dist/cjs/{getURL.js.map → getURL.cjs.map} +0 -0
  300. /package/dist/cjs/head/{Head.js.map → Head.cjs.map} +0 -0
  301. /package/dist/cjs/head/{HeadModule.js.map → HeadModule.cjs.map} +0 -0
  302. /package/dist/cjs/head/{index.js.map → index.cjs.map} +0 -0
  303. /package/dist/cjs/head/{types.js.map → types.cjs.map} +0 -0
  304. /package/dist/cjs/head/{url.js.map → url.cjs.map} +0 -0
  305. /package/dist/cjs/{hooks.js.map → hooks.cjs.map} +0 -0
  306. /package/dist/cjs/{imperative-api.js.map → imperative-api.cjs.map} +0 -0
  307. /package/dist/cjs/import-mode/{index.js.map → index.cjs.map} +0 -0
  308. /package/dist/cjs/import-mode/{index.web.js.map → index.web.cjs.map} +0 -0
  309. /package/dist/cjs/{index.js.map → index.cjs.map} +0 -0
  310. /package/dist/cjs/interfaces/{router.js.map → router.cjs.map} +0 -0
  311. /package/dist/cjs/layouts/{Drawer.js.map → Drawer.cjs.map} +0 -0
  312. /package/dist/cjs/layouts/{Stack.js.map → Stack.cjs.map} +0 -0
  313. /package/dist/cjs/layouts/{Tabs.js.map → Tabs.cjs.map} +0 -0
  314. /package/dist/cjs/layouts/{withLayoutContext.js.map → withLayoutContext.cjs.map} +0 -0
  315. /package/dist/cjs/link/{Link.js.map → Link.cjs.map} +0 -0
  316. /package/dist/cjs/link/{Redirect.js.map → Redirect.cjs.map} +0 -0
  317. /package/dist/cjs/link/{href.js.map → href.cjs.map} +0 -0
  318. /package/dist/cjs/link/{linking.js.map → linking.cjs.map} +0 -0
  319. /package/dist/cjs/link/{path.js.map → path.cjs.map} +0 -0
  320. /package/dist/cjs/link/{useLinkTo.js.map → useLinkTo.cjs.map} +0 -0
  321. /package/dist/cjs/link/{useLoadedNavigation.js.map → useLoadedNavigation.cjs.map} +0 -0
  322. /package/dist/cjs/{matchers.js.map → matchers.cjs.map} +0 -0
  323. /package/dist/cjs/{platform.js.map → platform.cjs.map} +0 -0
  324. /package/dist/cjs/{polyfills-mobile.js.map → polyfills-mobile.cjs.map} +0 -0
  325. /package/dist/cjs/{polyfills-server.js.map → polyfills-server.cjs.map} +0 -0
  326. /package/dist/cjs/{render.js.map → render.cjs.map} +0 -0
  327. /package/dist/cjs/router/{RouterStore.js.map → RouterStore.cjs.map} +0 -0
  328. /package/dist/cjs/router/{constants.js.map → constants.cjs.map} +0 -0
  329. /package/dist/cjs/router/{getNormalizedStatePath.js.map → getNormalizedStatePath.cjs.map} +0 -0
  330. /package/dist/cjs/router/{lastAction.js.map → lastAction.cjs.map} +0 -0
  331. /package/dist/cjs/router/{router.js.map → router.cjs.map} +0 -0
  332. /package/dist/cjs/router/{serverLocationContext.js.map → serverLocationContext.cjs.map} +0 -0
  333. /package/dist/cjs/router/{useInitializeOneRouter.js.map → useInitializeOneRouter.cjs.map} +0 -0
  334. /package/dist/cjs/{serve.js.map → serve.cjs.map} +0 -0
  335. /package/dist/cjs/server/{createRoutesManifest.js.map → createRoutesManifest.cjs.map} +0 -0
  336. /package/dist/cjs/server/{getServerManifest.js.map → getServerManifest.cjs.map} +0 -0
  337. /package/dist/cjs/{server-render.js.map → server-render.cjs.map} +0 -0
  338. /package/dist/cjs/{sortRoutes.js.map → sortRoutes.cjs.map} +0 -0
  339. /package/dist/cjs/typed-routes/{generateRouteTypes.js.map → generateRouteTypes.cjs.map} +0 -0
  340. /package/dist/cjs/typed-routes/{getTypedRoutesDeclarationFile.js.map → getTypedRoutesDeclarationFile.cjs.map} +0 -0
  341. /package/dist/cjs/{types.js.map → types.cjs.map} +0 -0
  342. /package/dist/cjs/{useFocusEffect.js.map → useFocusEffect.cjs.map} +0 -0
  343. /package/dist/cjs/{useLoader.js.map → useLoader.cjs.map} +0 -0
  344. /package/dist/cjs/{useNavigation.js.map → useNavigation.cjs.map} +0 -0
  345. /package/dist/cjs/{useScreens.js.map → useScreens.cjs.map} +0 -0
  346. /package/dist/cjs/{useViteRoutes.js.map → useViteRoutes.cjs.map} +0 -0
  347. /package/dist/cjs/utils/{assertIsReady.js.map → assertIsReady.cjs.map} +0 -0
  348. /package/dist/cjs/utils/{dynamicImport.js.map → dynamicImport.cjs.map} +0 -0
  349. /package/dist/cjs/utils/{existsAsync.js.map → existsAsync.cjs.map} +0 -0
  350. /package/dist/cjs/utils/{getPageExport.js.map → getPageExport.cjs.map} +0 -0
  351. /package/dist/cjs/utils/{globDir.js.map → globDir.cjs.map} +0 -0
  352. /package/dist/cjs/utils/{hashString.js.map → hashString.cjs.map} +0 -0
  353. /package/dist/cjs/utils/{isResponse.js.map → isResponse.cjs.map} +0 -0
  354. /package/dist/cjs/utils/{isStatus.js.map → isStatus.cjs.map} +0 -0
  355. /package/dist/cjs/utils/{promiseWithResolvers.js.map → promiseWithResolvers.cjs.map} +0 -0
  356. /package/dist/cjs/utils/{rand.js.map → rand.cjs.map} +0 -0
  357. /package/dist/cjs/utils/{redirect.js.map → redirect.cjs.map} +0 -0
  358. /package/dist/cjs/utils/{removeSearch.js.map → removeSearch.cjs.map} +0 -0
  359. /package/dist/cjs/utils/{removeUndefined.js.map → removeUndefined.cjs.map} +0 -0
  360. /package/dist/cjs/utils/{url.js.map → url.cjs.map} +0 -0
  361. /package/dist/cjs/utils/{weakKey.js.map → weakKey.cjs.map} +0 -0
  362. /package/dist/cjs/utils/{weakMemo.js.map → weakMemo.cjs.map} +0 -0
  363. /package/dist/cjs/views/{EmptyRoute.js.map → EmptyRoute.cjs.map} +0 -0
  364. /package/dist/cjs/views/{ErrorBoundary.js.map → ErrorBoundary.cjs.map} +0 -0
  365. /package/dist/cjs/views/{LoadProgressBar.js.map → LoadProgressBar.cjs.map} +0 -0
  366. /package/dist/cjs/views/{Navigator.js.map → Navigator.cjs.map} +0 -0
  367. /package/dist/cjs/views/{PreloadLinks.js.map → PreloadLinks.cjs.map} +0 -0
  368. /package/dist/cjs/views/{RootErrorBoundary.js.map → RootErrorBoundary.cjs.map} +0 -0
  369. /package/dist/cjs/views/{Screen.js.map → Screen.cjs.map} +0 -0
  370. /package/dist/cjs/views/{ScrollRestoration.js.map → ScrollRestoration.cjs.map} +0 -0
  371. /package/dist/cjs/views/{Try.js.map → Try.cjs.map} +0 -0
  372. /package/dist/cjs/vite/{build.js.map → build.cjs.map} +0 -0
  373. /package/dist/cjs/vite/{clientTreeShakePlugin.js.map → clientTreeShakePlugin.cjs.map} +0 -0
  374. /package/dist/cjs/vite/{constants.js.map → constants.cjs.map} +0 -0
  375. /package/dist/cjs/vite/{createFileSystemRouter.js.map → createFileSystemRouter.cjs.map} +0 -0
  376. /package/dist/cjs/vite/{customNodeExternals.js.map → customNodeExternals.cjs.map} +0 -0
  377. /package/dist/cjs/vite/{ensureTsConfig.js.map → ensureTsConfig.cjs.map} +0 -0
  378. /package/dist/cjs/vite/{findDepsToOptimize.js.map → findDepsToOptimize.cjs.map} +0 -0
  379. /package/dist/cjs/vite/{fixDependenciesPlugin.js.map → fixDependenciesPlugin.cjs.map} +0 -0
  380. /package/dist/cjs/vite/{generateTypesForRoutes.js.map → generateTypesForRoutes.cjs.map} +0 -0
  381. /package/dist/cjs/vite/{getManifest.js.map → getManifest.cjs.map} +0 -0
  382. /package/dist/cjs/vite/{headers.js.map → headers.cjs.map} +0 -0
  383. /package/dist/cjs/vite/{loadEnv.js.map → loadEnv.cjs.map} +0 -0
  384. /package/dist/cjs/vite/{makePluginWebOnly.js.map → makePluginWebOnly.cjs.map} +0 -0
  385. /package/dist/cjs/vite/{one.js.map → one.cjs.map} +0 -0
  386. /package/dist/cjs/vite/{removeReactNativeWebAnimatedPlugin.js.map → removeReactNativeWebAnimatedPlugin.cjs.map} +0 -0
  387. /package/dist/cjs/vite/{replaceLoader.js.map → replaceLoader.cjs.map} +0 -0
  388. /package/dist/cjs/vite/{resolveAPIRequest.js.map → resolveAPIRequest.cjs.map} +0 -0
  389. /package/dist/cjs/vite/{server.js.map → server.cjs.map} +0 -0
  390. /package/dist/cjs/vite/{types.js.map → types.cjs.map} +0 -0
  391. /package/dist/cjs/vite/{virtualEntryPlugin.js.map → virtualEntryPlugin.cjs.map} +0 -0
  392. /package/dist/cjs/vite/{vitePluginSsrCss.js.map → vitePluginSsrCss.cjs.map} +0 -0
  393. /package/dist/cjs/{vite.js.map → vite.cjs.map} +0 -0
  394. /package/dist/cjs/zero/{getQueryKey.js.map → getQueryKey.cjs.map} +0 -0
  395. /package/dist/cjs/zero/{isZeroQuery.js.map → isZeroQuery.cjs.map} +0 -0
  396. /package/dist/cjs/zero/{resolveQuery.js.map → resolveQuery.cjs.map} +0 -0
  397. /package/dist/cjs/zero/{subscribeToQuery.js.map → subscribeToQuery.cjs.map} +0 -0
  398. /package/dist/cjs/zero/{types.js.map → types.cjs.map} +0 -0
  399. /package/dist/cjs/zero/{useQuery.js.map → useQuery.cjs.map} +0 -0
  400. /package/dist/cjs/zero/{useQueryZero.js.map → useQueryZero.cjs.map} +0 -0
  401. /package/dist/cjs/{zero.js.map → zero.cjs.map} +0 -0
@@ -3,15 +3,21 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
3
  var __getOwnPropNames = Object.getOwnPropertyNames;
4
4
  var __hasOwnProp = Object.prototype.hasOwnProperty;
5
5
  var __export = (target, all) => {
6
- for (var name in all)
7
- __defProp(target, name, { get: all[name], enumerable: !0 });
8
- }, __copyProps = (to, from, except, desc) => {
9
- if (from && typeof from == "object" || typeof from == "function")
10
- for (let key of __getOwnPropNames(from))
11
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
12
- return to;
13
- };
14
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
6
+ for (var name in all) __defProp(target, name, {
7
+ get: all[name],
8
+ enumerable: !0
9
+ });
10
+ },
11
+ __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
13
+ get: () => from[key],
14
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
15
+ });
16
+ return to;
17
+ };
18
+ var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
19
+ value: !0
20
+ }), mod);
15
21
  var useQueryZero_exports = {};
16
22
  __export(useQueryZero_exports, {
17
23
  useQuery: () => useQuery
@@ -19,20 +25,20 @@ __export(useQueryZero_exports, {
19
25
  module.exports = __toCommonJS(useQueryZero_exports);
20
26
  var import_react = require("react");
21
27
  function useQuery(q, enable = !0) {
22
- const queryImpl = q, [snapshot, setSnapshot] = (0, import_react.useState)(void 0), [, setView] = (0, import_react.useState)(void 0);
28
+ const queryImpl = q,
29
+ [snapshot, setSnapshot] = (0, import_react.useState)(void 0),
30
+ [, setView] = (0, import_react.useState)(void 0);
23
31
  return (0, import_react.useLayoutEffect)(() => {
24
32
  if (enable) {
25
33
  const view = q.materialize();
26
34
  setView(view);
27
- const unsubscribe = view.addListener((snapshot2) => {
35
+ const unsubscribe = view.addListener(snapshot2 => {
28
36
  setSnapshot(structuredClone(snapshot2));
29
37
  });
30
38
  return view.hydrate(), () => {
31
39
  unsubscribe(), view.destroy();
32
40
  };
33
41
  }
34
- return setSnapshot(queryImpl.singular ? void 0 : []), setView(void 0), () => {
35
- };
42
+ return setSnapshot(queryImpl.singular ? void 0 : []), setView(void 0), () => {};
36
43
  }, [JSON.stringify(enable ? q.ast : null)]), snapshot;
37
- }
38
- //# sourceMappingURL=useQueryZero.js.map
44
+ }
@@ -0,0 +1,30 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
+ var __getOwnPropNames = Object.getOwnPropertyNames;
4
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
5
+ var __export = (target, all) => {
6
+ for (var name in all) __defProp(target, name, {
7
+ get: all[name],
8
+ enumerable: !0
9
+ });
10
+ },
11
+ __copyProps = (to, from, except, desc) => {
12
+ if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
13
+ get: () => from[key],
14
+ enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
15
+ });
16
+ return to;
17
+ };
18
+ var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
19
+ value: !0
20
+ }), mod);
21
+ var zero_exports = {};
22
+ __export(zero_exports, {
23
+ isZeroQuery: () => import_isZeroQuery.isZeroQuery,
24
+ resolveZeroQuery: () => import_resolveQuery.resolveZeroQuery,
25
+ useQuery: () => import_useQuery.useQuery
26
+ });
27
+ module.exports = __toCommonJS(zero_exports);
28
+ var import_useQuery = require("./zero/useQuery.cjs"),
29
+ import_resolveQuery = require("./zero/resolveQuery.cjs"),
30
+ import_isZeroQuery = require("./zero/isZeroQuery.cjs");
package/dist/esm/Root.js CHANGED
@@ -13,6 +13,7 @@ import { useInitializeOneRouter } from "./router/useInitializeOneRouter";
13
13
  import { PreloadLinks } from "./views/PreloadLinks";
14
14
  import { ScrollRestoration } from "./views/ScrollRestoration";
15
15
  import { rand } from "./utils/rand";
16
+ import { getURL } from "./getURL";
16
17
  import { Fragment as Fragment2, jsx, jsxs } from "react/jsx-runtime";
17
18
  typeof window < "u" && (window.__getReactRefreshIgnoredExports = () => ["feedCardQuery", "feedCardReplyQuery", "loader"]);
18
19
  function Root(props) {
@@ -99,7 +100,7 @@ window.$RefreshSig$ = () => (type) => type;`
99
100
  ] });
100
101
  }
101
102
  function Contents({ routes, path, wrapper = Fragment, routeOptions, ...props }) {
102
- const context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion), location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", "http://localhost");
103
+ const context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion), location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", getURL());
103
104
  return /* @__PURE__ */ jsx(ContextNavigator, { ...props, location, context, wrapper });
104
105
  }
105
106
  function ContextNavigator({
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Root.tsx"],
4
- "mappings": "AAAA,SAAS,UAAU,WAAW,gBAAwD;AAEtF,SAAS,qBAAqB;AAC9B,SAAS,yBAAyB;AAElC;AAAA,EACE;AAAA,EACA;AAAA,OAGK;AACP,SAAS,8BAA8B;AACvC,SAAS,sBAAsB;AAC/B,OAAO,iCAAiC;AACxC,SAAS,6BAA6B;AACtC,SAAS,8BAA8B;AACvC,SAAS,oBAAoB;AAC7B,SAAS,yBAAyB;AAElC,SAAS,YAAY;AAwCjB,SAoEA,YAAAA,WAlEE,KAFF;AArCA,OAAO,SAAW,QAEpB,OAAO,kCAAkC,MAAM,CAAC,iBAAiB,sBAAsB,QAAQ;AA8B1F,SAAS,KAAK,OAAkB;AAGrC,QAAM;AAAA;AAAA,IAEJ,qBAAC,qBAEC;AAAA,0BAAC,YAAyB,GAAG,SAAf,UAAsB;AAAA,MACpC,oBAAC,kBAAiB,eAAgB;AAAA,OACpC;AAAA;AAIF,MAAI,MAAM,UAAU;AAClB,QAAI,WAAW,wBAA2B,OAAO;AAE/C,YAAM,CAAC,MAAM,OAAO,IAAI,SAAS,EAAK;AAGtC,uBAAU,MAAM;AACd,gBAAQ,EAAI;AAAA,MACd,GAAG,CAAC,CAAC,GAEE,OAAO,WAAW;AAAA,IAC3B;AACA,WAAO;AAAA,EACT;AAEA,MAAI,EAAE,WAAW,IAAI;AAGrB,SAAI,YAAY,aAAa,SAAS,gBACpC,aAAa,SAIb,qBAAC,UAAK,MAAK,SACT;AAAA,yBAAC,UACE;AAAA,cAAQ,IAAI,aAAa,gBAAgB,oBAAC,WAAQ,IAAK;AAAA,MAExD;AAAA,QAAC;AAAA;AAA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,iBAAW;AAAA;AAAA;AACX;AAAA,IACF,KAAK;AAAA,IACL,KAAK;AAAA,IACL,KAAK;AACH,iBAAW;AAAA;AAAA;AACX;AAAA,EACJ;AAIA,MAFA,WAAW;AAAA;AAAA,uEAEP,QAAQ,IAAI,aAAa;AAC3B,UAAM,IAAI,MAAM,OAAO;AAEzB,UAAQ,MAAM,OAAO;AACvB,IAEA,oBAAoB,MAAM;AAAC;",
5
5
  "names": ["Fragment"]
6
6
  }
package/dist/esm/Root.mjs CHANGED
@@ -10,6 +10,7 @@ import { useInitializeOneRouter } from "./router/useInitializeOneRouter.mjs";
10
10
  import { PreloadLinks } from "./views/PreloadLinks.mjs";
11
11
  import { ScrollRestoration } from "./views/ScrollRestoration.mjs";
12
12
  import { rand } from "./utils/rand.mjs";
13
+ import { getURL } from "./getURL.mjs";
13
14
  import { Fragment as Fragment2, jsx, jsxs } from "react/jsx-runtime";
14
15
  typeof window < "u" && (window.__getReactRefreshIgnoredExports = () => ["feedCardQuery", "feedCardReplyQuery", "loader"]);
15
16
  function Root(props) {
@@ -101,7 +102,7 @@ function Contents({
101
102
  ...props
102
103
  }) {
103
104
  const context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion),
104
- location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", "http://localhost");
105
+ location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", getURL());
105
106
  return /* @__PURE__ */jsx(ContextNavigator, {
106
107
  ...props,
107
108
  location,
@@ -1 +1 @@
1
- {"version":3,"names":["Fragment","useEffect","useState","useViteRoutes","RootErrorBoundary","DarkTheme","DefaultTheme","SafeAreaProviderCompat","useColorScheme","UpstreamNavigationContainer","ServerLocationContext","useInitializeOneRouter","PreloadLinks","ScrollRestoration","rand","Fragment2","jsx","jsxs","window","__getReactRefreshIgnoredExports","Root","props","contents","children","Contents","isClient","globalThis","__vxrnHydrateMode__","show","setShow","loaderData","constructor","name","lang","process","env","NODE_ENV","DevHead","dangerouslySetInnerHTML","__html","css","map","file","rel","href","async","JSON","stringify","loaderProps","mode","ssrCSSID","as","type","routes","path","wrapper","routeOptions","context","__vxrnVersion","location","URL","ContextNavigator","ParentWrapper","initialLocation","navigationContainerProps","store","colorScheme","Component","rootComponent","Error","ref","navigationRef","initialState","linking","onUnhandledAction","theme","documentTitle","enabled","Provider","value","action","payload","message","console","error"],"sources":["../../src/Root.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,QAAA,EAAUC,SAAA,EAAWC,QAAA,QAAwD;AAEtF,SAASC,aAAA,QAAqB;AAC9B,SAASC,iBAAA,QAAyB;AAElC,SACEC,SAAA,EACAC,YAAA,QAGK;AACP,SAASC,sBAAA,QAA8B;AACvC,SAASC,cAAA,QAAsB;AAC/B,OAAOC,2BAAA,MAAiC;AACxC,SAASC,qBAAA,QAA6B;AACtC,SAASC,sBAAA,QAA8B;AACvC,SAASC,YAAA,QAAoB;AAC7B,SAASC,iBAAA,QAAyB;AAElC,SAASC,IAAA,QAAY;AAwCjB,SAoEAd,QAAA,IAAAe,SAAA,EAlEEC,GAAA,EAFFC,IAAA;AArCA,OAAOC,MAAA,GAAW,QAEpBA,MAAA,CAAOC,+BAAA,GAAkC,MAAM,CAAC,iBAAiB,sBAAsB,QAAQ;AA8B1F,SAASC,KAAKC,KAAA,EAAkB;EAGrC,MAAMC,QAAA;EAAA;EAEJ;EAAAL,IAAA,CAACb,iBAAA;IAECmB,QAAA,kBAAAP,GAAA,CAACQ,QAAA;MAAyB,GAAGH;IAAA,GAAf,UAAsB,GACpC,eAAAL,GAAA,CAACJ,YAAA,MAAiB,eAAgB;EAAA,CACpC;EAIF,IAAIS,KAAA,CAAMI,QAAA,EAAU;IAClB,IAAIC,UAAA,CAAWC,mBAAA,KAA2B,OAAO;MAE/C,MAAM,CAACC,IAAA,EAAMC,OAAO,IAAI3B,QAAA,CAAS,EAAK;MAGtC,OAAAD,SAAA,CAAU,MAAM;QACd4B,OAAA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W;AAAA;AAAA;MAGb;IACF,KAAK;IACL,KAAK;IACL,KAAK;MACHA,OAAA,IAAW;AAAA;AAAA;MACX;IACF,KAAK;IACL,KAAK;IACL,KAAK;MACHA,OAAA,IAAW;AAAA;AAAA;MACX;EACJ;EAIA,IAFAA,OAAA,IAAW;AAAA;AAAA,uEAEPhD,OAAA,CAAQC,GAAA,CAAIC,QAAA,KAAa,QAC3B,MAAM,IAAIiC,KAAA,CAAMa,OAAO;EAEzBC,OAAA,CAAQC,KAAA,CAAMF,OAAO;AACvB,IAEAR,iBAAA,GAAoBA,CAAA,KAAM,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["Fragment","useEffect","useState","useViteRoutes","RootErrorBoundary","DarkTheme","DefaultTheme","SafeAreaProviderCompat","useColorScheme","UpstreamNavigationContainer","ServerLocationContext","useInitializeOneRouter","PreloadLinks","ScrollRestoration","rand","getURL","Fragment2","jsx","jsxs","window","__getReactRefreshIgnoredExports","Root","props","contents","children","Contents","isClient","globalThis","__vxrnHydrateMode__","show","setShow","loaderData","constructor","name","lang","process","env","NODE_ENV","DevHead","dangerouslySetInnerHTML","__html","css","map","file","rel","href","async","JSON","stringify","loaderProps","mode","ssrCSSID","as","type","routes","path","wrapper","routeOptions","context","__vxrnVersion","location","URL","ContextNavigator","ParentWrapper","initialLocation","navigationContainerProps","store","colorScheme","Component","rootComponent","Error","ref","navigationRef","initialState","linking","onUnhandledAction","theme","documentTitle","enabled","Provider","value","action","payload","message","console","error"],"sources":["../../src/Root.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,QAAA,EAAUC,SAAA,EAAWC,QAAA,QAAwD;AAEtF,SAASC,aAAA,QAAqB;AAC9B,SAASC,iBAAA,QAAyB;AAElC,SACEC,SAAA,EACAC,YAAA,QAGK;AACP,SAASC,sBAAA,QAA8B;AACvC,SAASC,cAAA,QAAsB;AAC/B,OAAOC,2BAAA,MAAiC;AACxC,SAASC,qBAAA,QAA6B;AACtC,SAASC,sBAAA,QAA8B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,GAAGb,wBAAA;IAEJzC,QAAA,iBAAAP,GAAA,CAACP,qBAAA,CAAsBqE,QAAA,EAAtB;MAA+BC,KAAA,EAAOhB,eAAA;MACpCxC,QAAA,EAAAgC,OAAA,CAAQ,eAAAvC,GAAA,CAACmD,SAAA,IAAU,CAAE;IAAA,CACxB;EAAA,CACF;AAEJ;AAEA,IAAIO,iBAAA;AAEAxC,OAAA,CAAQC,GAAA,CAAIC,QAAA,KAAa,eAC3BsC,iBAAA,GAAqBM,MAAA,IAA6B;EAChD,MAAMC,OAAA,GAA2CD,MAAA,CAAOC,OAAA;EAExD,IAAIC,OAAA,GAAU,eAAeF,MAAA,CAAO5B,IAAI,IACtC6B,OAAA,GAAU,iBAAiBnC,IAAA,CAAKC,SAAA,CAAUiC,MAAA,CAAOC,OAAO,CAAC,KAAK,EAChE;EAEA,QAAQD,MAAA,CAAO5B,IAAA;IACb,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;MACC6B,OAAA,EAASjD,IAAA,GACXkD,OAAA,IAAW;AAAA;AAAA,6BAAkCD,OAAA,CAAQjD,IAAI,OAEzDkD,OAAA,IAAW;AAAA;AAAA;MAGb;IACF,KAAK;IACL,KAAK;IACL,KAAK;MACHA,OAAA,IAAW;AAAA;AAAA;MACX;IACF,KAAK;IACL,KAAK;IACL,KAAK;MACHA,OAAA,IAAW;AAAA;AAAA;MACX;EACJ;EAIA,IAFAA,OAAA,IAAW;AAAA;AAAA,uEAEPhD,OAAA,CAAQC,GAAA,CAAIC,QAAA,KAAa,QAC3B,MAAM,IAAIiC,KAAA,CAAMa,OAAO;EAEzBC,OAAA,CAAQC,KAAA,CAAMF,OAAO;AACvB,IAEAR,iBAAA,GAAoBA,CAAA,KAAM,CAAC","ignoreList":[]}
@@ -11,6 +11,7 @@ import { useInitializeOneRouter } from "./router/useInitializeOneRouter";
11
11
  import { PreloadLinks } from "./views/PreloadLinks";
12
12
  import { ScrollRestoration } from "./views/ScrollRestoration";
13
13
  import { rand } from "./utils/rand";
14
+ import { getURL } from "./getURL";
14
15
  typeof window < "u" && (window.__getReactRefreshIgnoredExports = function() {
15
16
  return [
16
17
  "feedCardQuery",
@@ -119,7 +120,7 @@ window.$RefreshSig$ = () => (type) => type;`
119
120
  });
120
121
  }
121
122
  function Contents(param) {
122
- var { routes, path, wrapper = Fragment, routeOptions, ...props } = param, context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion), location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", "http://localhost");
123
+ var { routes, path, wrapper = Fragment, routeOptions, ...props } = param, context = useViteRoutes(routes, routeOptions, globalThis.__vxrnVersion), location = typeof window < "u" && window.location ? new URL(path || window.location.href || "/", window.location.href) : new URL(path || "/", getURL());
123
124
  return /* @__PURE__ */ _jsx(ContextNavigator, {
124
125
  ...props,
125
126
  location,
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Users/n8/one/packages/one/src/Root.tsx"],
4
- "mappings": ";AAAA,SAASA,UAAUC,WAAWC,gBAAwD;AAEtF,SAASC,qBAAqB;AAC9B,SAASC,yBAAyB;AAElC,SACEC,WACAC,oBAGK;AACP,SAASC,8BAA8B;AACvC,SAASC,sBAAsB;AAC/B,OAAOC,iCAAiC;AACxC,SAASC,6BAA6B;AACtC,SAASC,8BAA8B;AACvC,SAASC,oBAAoB;AAC7B,SAASC,yBAAyB;AAElC,SAASC,YAAY;AAGjB,OAAOC,SAAW,QAEpBA,OAAOC,kCAAkC,WAAA;SAAM;IAAC;IAAiB;IAAsB;;;AA8BlF,SAASC,KAAKC,OAAgB;MA+B/BC,yBAeGD,YA3CDE;;IAEJ,sBAAChB,mBAAAA;;;QAEC,qBAACiB,UAAAA;UAAyB,GAAGH;WAAf,UAAA;QACd,qBAACN,cAAAA,CAAAA,GAAiB,eAAA;;;;AAKtB,MAAIM,MAAMI,UAAU;AAClB,QAAIC,WAAW,wBAA2B,OAAO;AAE/C,UAAM,CAACC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AeF,OAAO5B,IAAI,IACtC6B,UAAU,iBAAiBpC,KAAKC,UAAUkC,OAAOC,OAAO,CAAA,KAAM,EAAA;AAGhE,UAAQD,OAAO5B,MAAI;IACjB,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACH,MAAI6B,SAASxD,OACXyD,WAAW;;6BAAkCD,QAAQxD,IAAI,OAEzDyD,WAAW;;;AAGb;IACF,KAAK;IACL,KAAK;IACL,KAAK;AACHA,iBAAW;;;AACX;IACF,KAAK;IACL,KAAK;IACL,KAAK;AACHA,iBAAW;;;AACX;EACJ;AAIA,MAFAA,WAAW;;uEAEPpD,QAAQC,IAAIC,aAAa;AAC3B,UAAM,IAAIqC,MAAMa,OAAAA;AAElBC,UAAQC,MAAMF,OAAAA;AAChB,IAEAR,oBAAoB,WAAA;AAAO;",
5
- "names": ["Fragment", "useEffect", "useState", "useViteRoutes", "RootErrorBoundary", "DarkTheme", "DefaultTheme", "SafeAreaProviderCompat", "useColorScheme", "UpstreamNavigationContainer", "ServerLocationContext", "useInitializeOneRouter", "PreloadLinks", "ScrollRestoration", "rand", "window", "__getReactRefreshIgnoredExports", "Root", "props", "loaderData", "contents", "Contents", "isClient", "globalThis", "show", "setShow", "constructor", "name", "undefined", "html", "lang", "head", "process", "env", "NODE_ENV", "DevHead", "script", "dangerouslySetInnerHTML", "__html", "css", "map", "file", "link", "rel", "href", "body", "async", "JSON", "stringify", "loaderProps", "mode", "ssrCSSID", "as", "data-ssr-css", "type", "routes", "path", "wrapper", "routeOptions", "context", "location", "URL", "ContextNavigator", "ParentWrapper", "initialLocation", "navigationContainerProps", "store", "colorScheme", "children", "Component", "rootComponent", "Error", "ref", "navigationRef", "initialState", "linking", "onUnhandledAction", "theme", "documentTitle", "enabled", "Provider", "value", "action", "payload", "message", "console", "error"]
4
+ "mappings": ";AAAA,SAASA,UAAUC,WAAWC,gBAAwD;AAEtF,SAASC,qBAAqB;AAC9B,SAASC,yBAAyB;AAElC,SACEC,WACAC,oBAGK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AAA,CAAAA;;QAED,qBAACN,wBAAAA;;;;;EASP,GAEM+D,YAAYH,MAAMI;AAExB,MAAI,CAACD;AACH,UAAM,IAAIE,MAAM,yBAAyB;AAG3C,SACE,qBAAC/D,6BAAAA;IACCgE,KAAKN,MAAMO;IACXC,cAAcR,MAAMQ;IACpBC,SAAST,MAAMS;IACfC;IACAC,OAAOV,gBAAgB,SAAS/D,YAAYC;IAC5CyE,eAAe;MACbC,SAAS;IACX;IACC,GAAGd;cAEJ,qBAACxD,sBAAsBuE,UAAQ;MAACC,OAAOjB;gBACpCP,QAAQ,qBAACY,WAAAA,CAAAA,CAAAA,CAAAA;;;AAIlB;AAEA,IAAIO;AAEA5C,QAAQC,IAAIC,aAAa,eAC3B0C,oBAAoB,SAACM,QAAAA;AACnB,MAAMC,UAA2CD,OAAOC,SAEpDC,UAAU,eAAeF,OAAO5B,IAAI,IACtC6B,UAAU,iBAAiBpC,KAAKC,UAAUkC,OAAOC,OAAO,CAAA,KAAM,EAAA;AAGhE,UAAQD,OAAO5B,MAAI;IACjB,KAAK;IACL,KAAK;IACL,KAAK;IACL,KAAK;AACH,MAAI6B,SAASxD,OACXyD,WAAW;;6BAAkCD,QAAQxD,IAAI,OAEzDyD,WAAW;;;AAGb;IACF,KAAK;IACL,KAAK;IACL,KAAK;AACHA,iBAAW;;;AACX;IACF,KAAK;IACL,KAAK;IACL,KAAK;AACHA,iBAAW;;;AACX;EACJ;AAIA,MAFAA,WAAW;;uEAEPpD,QAAQC,IAAIC,aAAa;AAC3B,UAAM,IAAIqC,MAAMa,OAAAA;AAElBC,UAAQC,MAAMF,OAAAA;AAChB,IAEAR,oBAAoB,WAAA;AAAO;",
5
+ "names": ["Fragment", "useEffect", "useState", "useViteRoutes", "RootErrorBoundary", "DarkTheme", "DefaultTheme", "SafeAreaProviderCompat", "useColorScheme", "UpstreamNavigationContainer", "ServerLocationContext", "useInitializeOneRouter", "PreloadLinks", "ScrollRestoration", "rand", "getURL", "window", "__getReactRefreshIgnoredExports", "Root", "props", "loaderData", "contents", "Contents", "isClient", "globalThis", "show", "setShow", "constructor", "name", "undefined", "html", "lang", "head", "process", "env", "NODE_ENV", "DevHead", "script", "dangerouslySetInnerHTML", "__html", "css", "map", "file", "link", "rel", "href", "body", "async", "JSON", "stringify", "loaderProps", "mode", "ssrCSSID", "as", "data-ssr-css", "type", "routes", "path", "wrapper", "routeOptions", "context", "location", "URL", "ContextNavigator", "ParentWrapper", "initialLocation", "navigationContainerProps", "store", "colorScheme", "children", "Component", "rootComponent", "Error", "ref", "navigationRef", "initialState", "linking", "onUnhandledAction", "theme", "documentTitle", "enabled", "Provider", "value", "action", "payload", "message", "console", "error"]
6
6
  }
@@ -49,6 +49,7 @@ function createHandleRequest(options, handlers) {
49
49
  for (const route of pageRoutes) {
50
50
  if (route.file === "" || !route.workingRegex.test(finalUrl.pathname))
51
51
  continue;
52
+ process.env.NODE_ENV === "development" && console.info(` \u2776 Running loader for route: ${finalUrl.pathname}`);
52
53
  const headers = new Headers();
53
54
  headers.set("Content-Type", "text/javascript");
54
55
  try {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/createHandleRequest.ts"],
4
- "mappings": "AAAA,SAAS,6BAA6B;AAEtC,SAAS,kBAAkB;AAC3B,SAAS,4BAA4B;AACrC,SAAS,mBAAmB;AAYrB,SAAS,oBACd,SACA,UAKA;AACA,QAAM,WAAW,YAAY;AAC7B,MAAI,CAAC;AACH,UAAM,IAAI,MAAM,oBAAoB;AAGtC,QAAM,eACJ,SAAS,UAAU,OAAO,CAAC,KAAK,SAC9B,IAAI,IAAI,IAAI,IAAI,EAAE,GAAG,KAAK,eAAe,IAAI,OAAO,IAAI,UAAU,EAAE,GAC7D,MACN,CAAC,CAAC,GAED,gBAAgB,OAAO,OAAO,YAAY,GAK1C,iBAAiB,CAAC,GAGlB,aAAa,SAAS,WAAW,IAAI,CAAC,WAAW;AAAA,IACrD,GAAG;AAAA,IACH,cAAc,IAAI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AAE,IAAI,CAAC,CAAC,KAAK,KAAK,MAAM,CAAC,OAAO,MAAM,SAAS,GAAG,CAAC,CAAC;AAAA,EACpF,IAHmB,CAAC;AAItB;",
5
5
  "names": []
6
6
  }
@@ -52,6 +52,7 @@ function createHandleRequest(options, handlers) {
52
52
  finalUrl = new URL(originalUrl, url.origin);
53
53
  for (const route of pageRoutes) {
54
54
  if (route.file === "" || !route.workingRegex.test(finalUrl.pathname)) continue;
55
+ process.env.NODE_ENV === "development" && console.info(` \u2776 Running loader for route: ${finalUrl.pathname}`);
55
56
  const headers = new Headers();
56
57
  headers.set("Content-Type", "text/javascript");
57
58
  try {
@@ -1 +1 @@
1
- {"version":3,"names":["getPathFromLoaderPath","isResponse","promiseWithResolvers","getManifest","createHandleRequest","options","handlers","manifest","Error","apiRoutesMap","apiRoutes","reduce","acc","cur","page","compiledRegex","RegExp","namedRegex","apiRoutesList","Object","values","activeRequests","pageRoutes","map","route","workingRegex","handler","request","urlString","url","URL","headers","get","pathname","search","process","env","NODE_ENV","startsWith","handleAPI","apiRoute","find","test","params","getRouteParams","loaderProps","path","err","method","handleLoader","endsWith","originalUrl","finalUrl","origin","file","Headers","set","loaderResponse","getLoaderParams","Response","console","error","routes","handleSSR","promise","reject","resolve","ssrResponse","config","match","exec","groups","key","value","entries","namedKey","routeKeys","fromEntries"],"sources":["../../src/createHandleRequest.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,qBAAA,QAA6B;AAEtC,SAASC,UAAA,QAAkB;AAC3B,SAASC,oBAAA,QAA4B;AACrC,SAASC,WAAA,QAAmB;AAYrB,SAASC,oBACdC,OAAA,EACAC,QAAA,EAKA;EACA,MAAMC,QAAA,GAAWJ,WAAA,CAAY;EAC7B,IAAI,CAACI,QAAA,EACH,MAAM,IAAIC,KAAA,CAAM,oBAAoB;EAGtC,MAAMC,YAAA,GACJF,QAAA,CAASG,SAAA,CAAUC,MAAA,CAAO,CAACC,GAAA,EAAKC,GAAA,MAC9BD,GAAA,CA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GAAG;IACvD,MAAMI,QAAA,GAAWP,MAAA,CAAOQ,SAAA,CAAUJ,GAAG;IACrC7B,MAAA,CAAOgC,QAAQ,IAAIF,KAAA;EACrB;EAEF,OAAO9B,MAAA;AACT;AAGA,SAASC,eAAeX,QAAA,EAAkBT,KAAA,EAA0B;EAElE,MAAM6C,KAAA,GADQ,IAAIrD,MAAA,CAAOQ,KAAA,CAAMP,UAAU,EACrBqD,IAAA,CAAKrC,QAAQ;EACjC,OAAKoC,KAAA,GACElD,MAAA,CAAO0D,WAAA,CACZ1D,MAAA,CAAOuD,OAAA,CAAQlD,KAAA,CAAMoD,SAAS,EAAErD,GAAA,CAAI,CAAC,CAACiD,GAAA,EAAKC,KAAK,MAAM,CAACA,KAAA,EAAOJ,KAAA,CAAME,MAAA,GAASC,GAAG,CAAC,CAAC,CACpF,IAHmB,CAAC;AAItB","ignoreList":[]}
1
+ {"version":3,"names":["getPathFromLoaderPath","isResponse","promiseWithResolvers","getManifest","createHandleRequest","options","handlers","manifest","Error","apiRoutesMap","apiRoutes","reduce","acc","cur","page","compiledRegex","RegExp","namedRegex","apiRoutesList","Object","values","activeRequests","pageRoutes","map","route","workingRegex","handler","request","urlString","url","URL","headers","get","pathname","search","process","env","NODE_ENV","startsWith","handleAPI","apiRoute","find","test","params","getRouteParams","loaderProps","path","err","method","handleLoader","endsWith","originalUrl","finalUrl","origin","file","console","info","Headers","set","loaderResponse","getLoaderParams","Response","error","routes","handleSSR","promise","reject","resolve","ssrResponse","config","match","exec","groups","key","value","entries","namedKey","routeKeys","fromEntries"],"sources":["../../src/createHandleRequest.ts"],"sourcesContent":[null],"mappings":"AAAA,SAASA,qBAAA,QAA6B;AAEtC,SAASC,UAAA,QAAkB;AAC3B,SAASC,oBAAA,QAA4B;AACrC,SAASC,WAAA,QAAmB;AAYrB,SAASC,oBACdC,OAAA,EACAC,QAAA,EAKA;EACA,MAAMC,QAAA,GAAWJ,WAAA,CAAY;EAC7B,IAAI,CAACI,QAAA,EACH,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EACA;EACA,MAAM1B,MAAA,GAAiC,CAAC;IAClC2B,KAAA,GAAQ,IAAItD,MAAA,CAAOqD,MAAA,CAAO5C,YAAY,EAAE8C,IAAA,CAAK1C,GAAA,CAAII,QAAQ;EAC/D,IAAIqC,KAAA,EAAOE,MAAA,EACT,WAAW,CAACC,GAAA,EAAKC,KAAK,KAAKvD,MAAA,CAAOwD,OAAA,CAAQL,KAAA,CAAME,MAAM,GAAG;IACvD,MAAMI,QAAA,GAAWP,MAAA,CAAOQ,SAAA,CAAUJ,GAAG;IACrC9B,MAAA,CAAOiC,QAAQ,IAAIF,KAAA;EACrB;EAEF,OAAO/B,MAAA;AACT;AAGA,SAASC,eAAeX,QAAA,EAAkBT,KAAA,EAA0B;EAElE,MAAM8C,KAAA,GADQ,IAAItD,MAAA,CAAOQ,KAAA,CAAMP,UAAU,EACrBsD,IAAA,CAAKtC,QAAQ;EACjC,OAAKqC,KAAA,GACEnD,MAAA,CAAO2D,WAAA,CACZ3D,MAAA,CAAOwD,OAAA,CAAQnD,KAAA,CAAMqD,SAAS,EAAEtD,GAAA,CAAI,CAAC,CAACkD,GAAA,EAAKC,KAAK,MAAM,CAACA,KAAA,EAAOJ,KAAA,CAAME,MAAA,GAASC,GAAG,CAAC,CAAC,CACpF,IAHmB,CAAC;AAItB","ignoreList":[]}
@@ -59,6 +59,7 @@ function createHandleRequest(options, handlers) {
59
59
  for (var _iterator = pageRoutes[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = !0) {
60
60
  var route = _step.value;
61
61
  if (route.file !== "" && route.workingRegex.test(finalUrl.pathname)) {
62
+ process.env.NODE_ENV === "development" && console.info(` \u2776 Running loader for route: ${finalUrl.pathname}`);
62
63
  var headers = new Headers();
63
64
  headers.set("Content-Type", "text/javascript");
64
65
  try {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/Users/n8/one/packages/one/src/createHandleRequest.ts"],
4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,4BAAA,IAAoD;AAApD,YAAM,CAACE,KAAKC,KAAAA,IAAZ,MAAA,OACGC,WAAWP,OAAOQ,UAAUH,GAAAA;AAClC/B,eAAOiC,QAAAA,IAAYD;MACrB;;AAHK,0BAAA,IAAA,iBAAA;;;SAAA,6BAAA,UAAA,UAAA,QAAA,UAAA,OAAA;;YAAA;gBAAA;;;EAIP;AACA,SAAOhC;AACT;AAGA,SAASC,eAAeZ,UAAkBT,OAAwB;AAChE,MAAMkB,QAAQ,IAAI1B,OAAOQ,MAAMP,UAAU,GACnCsD,QAAQ7B,MAAM8B,KAAKvC,QAAAA;AACzB,SAAKsC,QACEpD,OAAO4D,YACZ5D,OAAOuD,QAAQlD,MAAMsD,SAAS,EAAEvD,IAAI,SAAA,OAAA;QAAC,CAACoD,KAAKC,KAAAA,IAAM,OAAaL;WAAR;MAACK;OAAOL,gBAAAA,MAAME,YAAM,QAAZF,kBAAAA,SAAAA,SAAAA,cAAeI,GAAAA;;QAF5D,CAAC;AAItB;",
5
- "names": ["getPathFromLoaderPath", "isResponse", "promiseWithResolvers", "getManifest", "createHandleRequest", "options", "handlers", "manifest", "Error", "apiRoutesMap", "apiRoutes", "reduce", "acc", "cur", "page", "compiledRegex", "RegExp", "namedRegex", "apiRoutesList", "Object", "values", "activeRequests", "pageRoutes", "map", "route", "workingRegex", "handler", "request", "urlString", "url", "URL", "headers", "get", "pathname", "search", "process", "env", "NODE_ENV", "startsWith", "handleAPI", "apiRoute", "find", "regex", "test", "params", "getRouteParams", "loaderProps", "path", "err", "method", "handleLoader", "isClientRequestingNewRoute", "endsWith", "originalUrl", "finalUrl", "origin", "file", "Headers", "set", "loaderResponse", "getLoaderParams", "Response", "console", "error", "routes", "handleSSR", "promise", "reject", "resolve", "ssrResponse", "config", "match", "exec", "groups", "entries", "key", "value", "namedKey", "routeKeys", "fromEntries"]
4
+ "mappings": "AAAA,SAASA,6BAA6B;AAEtC,SAASC,kBAAkB;AAC3B,SAASC,4BAA4B;AACrC,SAAS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,GAAA,OAAA,4BAAA,IAAoD;AAApD,YAAM,CAACE,KAAKC,KAAAA,IAAZ,MAAA,OACGC,WAAWP,OAAOQ,UAAUH,GAAAA;AAClChC,eAAOkC,QAAAA,IAAYD;MACrB;;AAHK,0BAAA,IAAA,iBAAA;;;SAAA,6BAAA,UAAA,UAAA,QAAA,UAAA,OAAA;;YAAA;gBAAA;;;EAIP;AACA,SAAOjC;AACT;AAGA,SAASC,eAAeZ,UAAkBT,OAAwB;AAChE,MAAMkB,QAAQ,IAAI1B,OAAOQ,MAAMP,UAAU,GACnCuD,QAAQ9B,MAAM+B,KAAKxC,QAAAA;AACzB,SAAKuC,QACErD,OAAO6D,YACZ7D,OAAOwD,QAAQnD,MAAMuD,SAAS,EAAExD,IAAI,SAAA,OAAA;QAAC,CAACqD,KAAKC,KAAAA,IAAM,OAAaL;WAAR;MAACK;OAAOL,gBAAAA,MAAME,YAAM,QAAZF,kBAAAA,SAAAA,SAAAA,cAAeI,GAAAA;;QAF5D,CAAC;AAItB;",
5
+ "names": ["getPathFromLoaderPath", "isResponse", "promiseWithResolvers", "getManifest", "createHandleRequest", "options", "handlers", "manifest", "Error", "apiRoutesMap", "apiRoutes", "reduce", "acc", "cur", "page", "compiledRegex", "RegExp", "namedRegex", "apiRoutesList", "Object", "values", "activeRequests", "pageRoutes", "map", "route", "workingRegex", "handler", "request", "urlString", "url", "URL", "headers", "get", "pathname", "search", "process", "env", "NODE_ENV", "startsWith", "handleAPI", "apiRoute", "find", "regex", "test", "params", "getRouteParams", "loaderProps", "path", "err", "method", "handleLoader", "isClientRequestingNewRoute", "endsWith", "originalUrl", "finalUrl", "origin", "file", "console", "info", "Headers", "set", "loaderResponse", "getLoaderParams", "Response", "error", "routes", "handleSSR", "promise", "reject", "resolve", "ssrResponse", "config", "match", "exec", "groups", "entries", "key", "value", "namedKey", "routeKeys", "fromEntries"]
6
6
  }
@@ -1,6 +1,6 @@
1
1
  const CLIENT_BASE_URL = typeof window < "u" && window.location ? `${window.location.protocol}//${window.location.host}` : "";
2
2
  function getURL() {
3
- return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || "";
3
+ return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || "http://localhost";
4
4
  }
5
5
  export {
6
6
  getURL
@@ -1,6 +1,6 @@
1
1
  const CLIENT_BASE_URL = typeof window < "u" && window.location ? `${window.location.protocol}//${window.location.host}` : "";
2
2
  function getURL() {
3
- return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || "";
3
+ return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || "http://localhost";
4
4
  }
5
5
  export { getURL };
6
6
  //# sourceMappingURL=getURL.mjs.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "one",
3
- "version": "1.1.309",
3
+ "version": "1.1.311",
4
4
  "source": "src/index.ts",
5
5
  "types": "./types/index.d.ts",
6
6
  "sideEffects": false,
@@ -29,11 +29,11 @@
29
29
  "exports": {
30
30
  "./package.json": "./package.json",
31
31
  ".": {
32
- "types": "./types/index.d.ts",
33
32
  "react-native-import": "./dist/esm/index.native.js",
34
33
  "react-native": "./dist/cjs/index.native.js",
34
+ "types": "./types/index.d.ts",
35
35
  "import": "./dist/esm/index.mjs",
36
- "require": "./dist/cjs/index.js"
36
+ "require": "./dist/cjs/index.cjs"
37
37
  },
38
38
  "./vite": {
39
39
  "types": "./types/vite.d.ts",
@@ -90,14 +90,14 @@
90
90
  "@react-navigation/native-stack": "~6.9.13",
91
91
  "@react-navigation/routers": "~6.1.9",
92
92
  "@ungap/structured-clone": "^1.2.0",
93
- "@vxrn/resolve": "1.1.309",
94
- "@vxrn/tslib-lite": "1.1.309",
95
- "@vxrn/universal-color-scheme": "1.1.309",
96
- "@vxrn/use-isomorphic-layout-effect": "1.1.309",
93
+ "@vxrn/resolve": "1.1.311",
94
+ "@vxrn/tslib-lite": "1.1.311",
95
+ "@vxrn/universal-color-scheme": "1.1.311",
96
+ "@vxrn/use-isomorphic-layout-effect": "1.1.311",
97
97
  "babel-dead-code-elimination": "^1.0.6",
98
98
  "citty": "^0.1.6",
99
99
  "core-js": "^3.38.1",
100
- "create-vxrn": "1.1.309",
100
+ "create-vxrn": "1.1.311",
101
101
  "dotenv": "^16.4.5",
102
102
  "escape-string-regexp": "^5.0.0",
103
103
  "expo-linking": "~6.3.1",
@@ -120,7 +120,7 @@
120
120
  "url-parse": "^1.5.10",
121
121
  "vite": "6.0.0-beta.1",
122
122
  "vite-tsconfig-paths": "^5.0.1",
123
- "vxrn": "1.1.309",
123
+ "vxrn": "1.1.311",
124
124
  "ws": "^8.18.0",
125
125
  "xxhashjs": "^0.2.2"
126
126
  },
@@ -128,7 +128,7 @@
128
128
  "react-native": "*"
129
129
  },
130
130
  "devDependencies": {
131
- "@tamagui/build": "^1.114.4",
131
+ "@tamagui/build": "^1.115.0",
132
132
  "@types/node": "^22.1.0",
133
133
  "@types/react-dom": "^18.2.25",
134
134
  "@types/url-parse": "^1.4.11",
package/src/Root.tsx CHANGED
@@ -18,6 +18,7 @@ import { PreloadLinks } from './views/PreloadLinks'
18
18
  import { ScrollRestoration } from './views/ScrollRestoration'
19
19
  import type { One } from './vite/types'
20
20
  import { rand } from './utils/rand'
21
+ import { getURL } from './getURL'
21
22
  // import { SplashScreen } from './views/Splash'
22
23
 
23
24
  if (typeof window !== 'undefined') {
@@ -160,7 +161,7 @@ function Contents({ routes, path, wrapper = Fragment, routeOptions, ...props }:
160
161
  const location =
161
162
  typeof window !== 'undefined' && window.location
162
163
  ? new URL(path || window.location.href || '/', window.location.href)
163
- : new URL(path || '/', 'http://localhost')
164
+ : new URL(path || '/', getURL())
164
165
 
165
166
  return <ContextNavigator {...props} location={location} context={context} wrapper={wrapper} />
166
167
  }
@@ -111,10 +111,15 @@ export function createHandleRequest(
111
111
  // TODO improve/remove when not found is fixed
112
112
  continue
113
113
  }
114
+
114
115
  if (!route.workingRegex.test(finalUrl.pathname)) {
115
116
  continue
116
117
  }
117
118
 
119
+ if (process.env.NODE_ENV === 'development') {
120
+ console.info(` ❶ Running loader for route: ${finalUrl.pathname}`)
121
+ }
122
+
118
123
  const headers = new Headers()
119
124
  headers.set('Content-Type', 'text/javascript')
120
125
 
package/src/getURL.ts CHANGED
@@ -6,5 +6,5 @@ const CLIENT_BASE_URL =
6
6
  export function getURL() {
7
7
  // We should use `CLIENT_BASE_URL` on the client as we can't guarantee how the client is connected to the server - it's possible that the server is listening on `127.0.0.1` and the client is connected via `localhost`. Things might break if URLs don't match due to a JS module being double-loaded via two different URLs.
8
8
  // `process.env.ONE_SERVER_URL` is for the server, where `CLIENT_BASE_URL` will be blank.
9
- return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || ''
9
+ return CLIENT_BASE_URL || process.env.ONE_SERVER_URL || 'http://localhost'
10
10
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Root.d.ts","sourceRoot":"","sources":["../src/Root.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAiC,KAAK,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAC7F,OAAO,KAAK,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,SAAS,CAAA;AAIlE,OAAO,EAIL,KAAK,wBAAwB,EAC9B,MAAM,0BAA0B,CAAA;AAQjC,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,cAAc,CAAA;AASvC,KAAK,SAAS,GAAG,cAAc,GAC7B,IAAI,CAAC,UAAU,EAAE,SAAS,CAAC,GAAG;IAC5B,IAAI,CAAC,EAAE,GAAG,CAAC,eAAe,CAAA;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,EAAE,mBAAmB,CAAA;IAC3B,YAAY,CAAC,EAAE,GAAG,CAAC,YAAY,CAAA;CAChC,CAAA;AAEH,KAAK,UAAU,GAAG;IAChB,OAAO,EAAE,GAAG,CAAC,YAAY,CAAA;IACzB,QAAQ,CAAC,EAAE,GAAG,CAAA;IACd,OAAO,CAAC,EAAE,iBAAiB,CAAC;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