one 1.1.310 → 1.1.312

Sign up to get free protection for your applications and to get access to all the features.
Files changed (186) hide show
  1. package/dist/cjs/Root.cjs +2 -1
  2. package/dist/cjs/Root.cjs.map +1 -1
  3. package/dist/cjs/Root.native.js +2 -2
  4. package/dist/cjs/Root.native.js.map +2 -2
  5. package/dist/cjs/cleanUrl.cjs +3 -8
  6. package/dist/cjs/cleanUrl.cjs.map +2 -2
  7. package/dist/cjs/cleanUrl.native.js +5 -8
  8. package/dist/cjs/cleanUrl.native.js.map +2 -2
  9. package/dist/cjs/cli.cjs +0 -2
  10. package/dist/cjs/cli.cjs.map +1 -1
  11. package/dist/cjs/cli.native.js +1 -2
  12. package/dist/cjs/cli.native.js.map +2 -2
  13. package/dist/cjs/config.cjs +1 -1
  14. package/dist/cjs/config.native.js +1 -1
  15. package/dist/cjs/config.native.js.map +1 -1
  16. package/dist/cjs/constants.cjs +9 -1
  17. package/dist/cjs/constants.cjs.map +1 -1
  18. package/dist/cjs/constants.native.js +9 -1
  19. package/dist/cjs/constants.native.js.map +2 -2
  20. package/dist/cjs/createApp.native.cjs +1 -1
  21. package/dist/cjs/createApp.native.js +1 -1
  22. package/dist/cjs/createApp.native.js.map +1 -1
  23. package/dist/cjs/createHandleRequest.cjs +3 -1
  24. package/dist/cjs/createHandleRequest.cjs.map +1 -1
  25. package/dist/cjs/createHandleRequest.native.js +3 -2
  26. package/dist/cjs/createHandleRequest.native.js.map +2 -2
  27. package/dist/cjs/getURL.cjs +1 -1
  28. package/dist/cjs/matchers.cjs +1 -1
  29. package/dist/cjs/matchers.cjs.map +1 -1
  30. package/dist/cjs/matchers.native.js +1 -1
  31. package/dist/cjs/matchers.native.js.map +1 -1
  32. package/dist/cjs/serve.cjs +3 -3
  33. package/dist/cjs/serve.cjs.map +1 -1
  34. package/dist/cjs/serve.native.js +2 -2
  35. package/dist/cjs/serve.native.js.map +2 -2
  36. package/dist/cjs/useLoader.cjs +1 -1
  37. package/dist/cjs/useLoader.native.js +1 -1
  38. package/dist/cjs/vite/build.cjs +2 -2
  39. package/dist/cjs/vite/build.cjs.map +1 -1
  40. package/dist/cjs/vite/build.native.js +1 -1
  41. package/dist/cjs/vite/build.native.js.map +1 -1
  42. package/dist/cjs/vite/clientTreeShakePlugin.cjs +1 -1
  43. package/dist/cjs/vite/clientTreeShakePlugin.native.js +1 -1
  44. package/dist/cjs/vite/createFileSystemRouter.cjs +1 -1
  45. package/dist/cjs/vite/createFileSystemRouter.native.js +1 -1
  46. package/dist/cjs/vite/one.cjs +43 -14
  47. package/dist/cjs/vite/one.cjs.map +1 -1
  48. package/dist/cjs/vite/one.native.js +39 -12
  49. package/dist/cjs/vite/one.native.js.map +2 -2
  50. package/dist/cjs/vite/virtualEntryPlugin.cjs +5 -5
  51. package/dist/cjs/vite/virtualEntryPlugin.native.js +5 -5
  52. package/dist/cjs/vite/virtualEntryPlugin.native.js.map +1 -1
  53. package/dist/cjs/vite/vitePluginSsrCss.cjs +1 -1
  54. package/dist/cjs/vite/vitePluginSsrCss.native.js +1 -1
  55. package/dist/esm/Root.js +2 -1
  56. package/dist/esm/Root.js.map +1 -1
  57. package/dist/esm/Root.mjs +2 -1
  58. package/dist/esm/Root.mjs.map +1 -1
  59. package/dist/esm/Root.native.js +2 -1
  60. package/dist/esm/Root.native.js.map +2 -2
  61. package/dist/esm/cleanUrl.js +10 -9
  62. package/dist/esm/cleanUrl.js.map +1 -1
  63. package/dist/esm/cleanUrl.mjs +4 -9
  64. package/dist/esm/cleanUrl.mjs.map +1 -1
  65. package/dist/esm/cleanUrl.native.js +5 -9
  66. package/dist/esm/cleanUrl.native.js.map +2 -2
  67. package/dist/esm/cli.js +0 -2
  68. package/dist/esm/cli.js.map +1 -1
  69. package/dist/esm/cli.mjs +0 -2
  70. package/dist/esm/cli.mjs.map +1 -1
  71. package/dist/esm/cli.native.js +0 -2
  72. package/dist/esm/cli.native.js.map +2 -2
  73. package/dist/esm/config.js +1 -1
  74. package/dist/esm/config.mjs +1 -1
  75. package/dist/esm/config.mjs.map +1 -1
  76. package/dist/esm/config.native.js +1 -1
  77. package/dist/esm/config.native.js.map +1 -1
  78. package/dist/esm/constants.js +5 -1
  79. package/dist/esm/constants.js.map +1 -1
  80. package/dist/esm/constants.mjs +6 -2
  81. package/dist/esm/constants.mjs.map +1 -1
  82. package/dist/esm/constants.native.js +5 -1
  83. package/dist/esm/constants.native.js.map +2 -2
  84. package/dist/esm/createApp.native.js +1 -1
  85. package/dist/esm/createApp.native.js.map +1 -1
  86. package/dist/esm/createHandleRequest.js +3 -1
  87. package/dist/esm/createHandleRequest.js.map +1 -1
  88. package/dist/esm/createHandleRequest.mjs +3 -1
  89. package/dist/esm/createHandleRequest.mjs.map +1 -1
  90. package/dist/esm/createHandleRequest.native.js +3 -1
  91. package/dist/esm/createHandleRequest.native.js.map +2 -2
  92. package/dist/esm/getURL.js +1 -1
  93. package/dist/esm/getURL.mjs +1 -1
  94. package/dist/esm/matchers.js +1 -1
  95. package/dist/esm/matchers.js.map +1 -1
  96. package/dist/esm/matchers.mjs +1 -1
  97. package/dist/esm/matchers.mjs.map +1 -1
  98. package/dist/esm/matchers.native.js +1 -1
  99. package/dist/esm/matchers.native.js.map +1 -1
  100. package/dist/esm/serve.js +4 -4
  101. package/dist/esm/serve.js.map +1 -1
  102. package/dist/esm/serve.mjs +4 -4
  103. package/dist/esm/serve.mjs.map +1 -1
  104. package/dist/esm/serve.native.js +4 -4
  105. package/dist/esm/serve.native.js.map +2 -2
  106. package/dist/esm/useLoader.js +1 -1
  107. package/dist/esm/useLoader.mjs +1 -1
  108. package/dist/esm/useLoader.native.js +1 -1
  109. package/dist/esm/vite/build.js +1 -1
  110. package/dist/esm/vite/build.js.map +1 -1
  111. package/dist/esm/vite/build.mjs +1 -1
  112. package/dist/esm/vite/build.mjs.map +1 -1
  113. package/dist/esm/vite/build.native.js +1 -1
  114. package/dist/esm/vite/build.native.js.map +2 -2
  115. package/dist/esm/vite/clientTreeShakePlugin.js +1 -1
  116. package/dist/esm/vite/clientTreeShakePlugin.mjs +1 -1
  117. package/dist/esm/vite/clientTreeShakePlugin.native.js +1 -1
  118. package/dist/esm/vite/createFileSystemRouter.js +1 -1
  119. package/dist/esm/vite/createFileSystemRouter.mjs +1 -1
  120. package/dist/esm/vite/createFileSystemRouter.native.js +1 -1
  121. package/dist/esm/vite/one.js +43 -14
  122. package/dist/esm/vite/one.js.map +1 -1
  123. package/dist/esm/vite/one.mjs +43 -14
  124. package/dist/esm/vite/one.mjs.map +1 -1
  125. package/dist/esm/vite/one.native.js +41 -14
  126. package/dist/esm/vite/one.native.js.map +2 -2
  127. package/dist/esm/vite/virtualEntryPlugin.js +5 -5
  128. package/dist/esm/vite/virtualEntryPlugin.mjs +5 -5
  129. package/dist/esm/vite/virtualEntryPlugin.mjs.map +1 -1
  130. package/dist/esm/vite/virtualEntryPlugin.native.js +5 -5
  131. package/dist/esm/vite/virtualEntryPlugin.native.js.map +1 -1
  132. package/dist/esm/vite/vitePluginSsrCss.js +1 -1
  133. package/dist/esm/vite/vitePluginSsrCss.mjs +1 -1
  134. package/dist/esm/vite/vitePluginSsrCss.native.js +1 -1
  135. package/package.json +8 -8
  136. package/src/Root.tsx +2 -1
  137. package/src/cleanUrl.ts +10 -14
  138. package/src/cli.ts +0 -3
  139. package/src/config.ts +1 -1
  140. package/src/constants.ts +6 -0
  141. package/src/createApp.native.tsx +2 -2
  142. package/src/createHandleRequest.ts +7 -1
  143. package/src/getURL.ts +1 -1
  144. package/src/matchers.ts +1 -1
  145. package/src/serve.ts +5 -3
  146. package/src/useLoader.ts +1 -1
  147. package/src/vite/build.ts +2 -1
  148. package/src/vite/clientTreeShakePlugin.ts +1 -1
  149. package/src/vite/createFileSystemRouter.tsx +1 -1
  150. package/src/vite/one.ts +44 -11
  151. package/src/vite/virtualEntryPlugin.ts +5 -5
  152. package/src/vite/vitePluginSsrCss.ts +1 -1
  153. package/types/Root.d.ts.map +1 -1
  154. package/types/cleanUrl.d.ts.map +1 -1
  155. package/types/constants.d.ts +4 -0
  156. package/types/constants.d.ts.map +1 -1
  157. package/types/createHandleRequest.d.ts.map +1 -1
  158. package/types/serve.d.ts.map +1 -1
  159. package/types/vite/build.d.ts.map +1 -1
  160. package/types/vite/one.d.ts.map +1 -1
  161. package/dist/cjs/router/constants.cjs +0 -26
  162. package/dist/cjs/router/constants.cjs.map +0 -6
  163. package/dist/cjs/router/constants.native.js +0 -26
  164. package/dist/cjs/router/constants.native.js.map +0 -6
  165. package/dist/cjs/vite/loadEnv.cjs +0 -47
  166. package/dist/cjs/vite/loadEnv.cjs.map +0 -6
  167. package/dist/cjs/vite/loadEnv.native.js +0 -44
  168. package/dist/cjs/vite/loadEnv.native.js.map +0 -6
  169. package/dist/esm/router/constants.js +0 -5
  170. package/dist/esm/router/constants.js.map +0 -6
  171. package/dist/esm/router/constants.mjs +0 -3
  172. package/dist/esm/router/constants.mjs.map +0 -1
  173. package/dist/esm/router/constants.native.js +0 -5
  174. package/dist/esm/router/constants.native.js.map +0 -6
  175. package/dist/esm/vite/loadEnv.js +0 -13
  176. package/dist/esm/vite/loadEnv.js.map +0 -6
  177. package/dist/esm/vite/loadEnv.mjs +0 -13
  178. package/dist/esm/vite/loadEnv.mjs.map +0 -1
  179. package/dist/esm/vite/loadEnv.native.js +0 -16
  180. package/dist/esm/vite/loadEnv.native.js.map +0 -6
  181. package/src/router/constants.ts +0 -4
  182. package/src/vite/loadEnv.ts +0 -11
  183. package/types/router/constants.d.ts +0 -2
  184. package/types/router/constants.d.ts.map +0 -1
  185. package/types/vite/loadEnv.d.ts +0 -2
  186. package/types/vite/loadEnv.d.ts.map +0 -1
package/src/vite/build.ts CHANGED
@@ -13,13 +13,13 @@ import {
13
13
  type ClientManifestEntry,
14
14
  } from 'vxrn'
15
15
  import { getLoaderPath, getPreloadPath } from '../cleanUrl'
16
+ import { labelProcess } from '../cli/label-process'
16
17
  import type { RouteInfo } from '../server/createRoutesManifest'
17
18
  import type { LoaderProps, RenderApp } from '../types'
18
19
  import { getManifest } from './getManifest'
19
20
  import { loadUserOneOptions } from './one'
20
21
  import { replaceLoader } from './replaceLoader'
21
22
  import type { One } from './types'
22
- import { labelProcess } from '../cli/label-process'
23
23
 
24
24
  const { ensureDir, readFile, outputFile } = FSExtra
25
25
 
@@ -32,6 +32,7 @@ export async function build(args: {
32
32
  only?: string
33
33
  }) {
34
34
  labelProcess('build')
35
+
35
36
  const userOptions = await loadUserOneOptions('build')
36
37
  const serverOutputFormat = userOptions.build?.server?.outputFormat ?? 'esm'
37
38
 
@@ -10,7 +10,7 @@ const generate = BabelGenerate['default'] as any as typeof BabelGenerate
10
10
 
11
11
  export const clientTreeShakePlugin = (): Plugin => {
12
12
  return {
13
- name: 'one:client-tree-shake',
13
+ name: 'one-client-tree-shake',
14
14
 
15
15
  enforce: 'pre',
16
16
 
@@ -173,7 +173,7 @@ export function createFileSystemRouter(options: One.PluginOptions): Plugin {
173
173
  }
174
174
 
175
175
  return {
176
- name: `router-fs`,
176
+ name: `one-router-fs`,
177
177
  enforce: 'post',
178
178
  apply: 'serve',
179
179
 
package/src/vite/one.ts CHANGED
@@ -1,17 +1,17 @@
1
+ import { resolvePath } from '@vxrn/resolve'
1
2
  import events from 'node:events'
2
3
  import path, { dirname, resolve } from 'node:path'
3
4
  import { type Plugin, type PluginOption, type UserConfig, loadConfigFromFile } from 'vite'
4
5
  import tsconfigPaths from 'vite-tsconfig-paths'
5
- import { getOptimizeDeps, getOptionsFilled, isWebEnvironment } from 'vxrn'
6
+ import { getOptimizeDeps, getOptionsFilled, isWebEnvironment, loadEnv } from 'vxrn'
7
+ import { CACHE_KEY } from '../constants'
6
8
  import '../polyfills-server'
7
9
  import { existsAsync } from '../utils/existsAsync'
8
- import { resolvePath } from '@vxrn/resolve'
9
10
  import { clientTreeShakePlugin } from './clientTreeShakePlugin'
10
11
  import { createFileSystemRouter } from './createFileSystemRouter'
11
12
  import { ensureTSConfig } from './ensureTsConfig'
12
13
  import { fixDependenciesPlugin } from './fixDependenciesPlugin'
13
14
  import { generateTypesForRoutes } from './generateTypesForRoutes'
14
- import { loadEnv } from './loadEnv'
15
15
  import type { One } from './types'
16
16
  import { createVirtualEntry, virtualEntryId } from './virtualEntryPlugin'
17
17
  import { vitePluginSsrCss } from './vitePluginSsrCss'
@@ -24,8 +24,6 @@ globalThis.__vxrnEnableNativeEnv = true
24
24
  export function one(options: One.PluginOptions = {}): PluginOption {
25
25
  oneOptions = options
26
26
 
27
- void loadEnv(process.cwd())
28
-
29
27
  // ensure tsconfig
30
28
  if (options.config?.ensureTSConfig !== false) {
31
29
  void ensureTSConfig()
@@ -46,7 +44,18 @@ export function one(options: One.PluginOptions = {}): PluginOption {
46
44
 
47
45
  const vxrnOptions = getOptionsFilled()
48
46
 
47
+ const { clientEnvDefine } = loadEnv(vxrnOptions?.mode ?? 'development')
48
+
49
49
  const devAndProdPlugins = [
50
+ {
51
+ name: 'one-define-env',
52
+ config() {
53
+ return {
54
+ define: clientEnvDefine,
55
+ }
56
+ },
57
+ },
58
+
50
59
  // proxy because you cant add a plugin inside a plugin
51
60
  new Proxy(
52
61
  {
@@ -126,16 +135,20 @@ export function one(options: One.PluginOptions = {}): PluginOption {
126
135
  return {
127
136
  define: {
128
137
  ...(options.web?.defaultRenderMode && {
129
- 'process.env.One_DEFAULT_RENDER_MODE': JSON.stringify(options.web.defaultRenderMode),
138
+ 'process.env.ONE_DEFAULT_RENDER_MODE': JSON.stringify(options.web.defaultRenderMode),
139
+ 'import.meta.env.ONE_DEFAULT_RENDER_MODE': JSON.stringify(
140
+ options.web.defaultRenderMode
141
+ ),
130
142
  }),
131
143
 
132
144
  ...(options.setupFile && {
133
- 'process.env.One_SETUP_FILE': JSON.stringify(options.setupFile),
145
+ 'process.env.ONE_SETUP_FILE': JSON.stringify(options.setupFile),
134
146
  }),
135
147
 
136
148
  ...(process.env.NODE_ENV !== 'production' &&
137
149
  vxrnOptions && {
138
150
  'process.env.ONE_SERVER_URL': JSON.stringify(vxrnOptions.server.url),
151
+ 'import.meta.env.ONE_SERVER_URL': JSON.stringify(vxrnOptions.server.url),
139
152
  }),
140
153
  },
141
154
 
@@ -143,12 +156,28 @@ export function one(options: One.PluginOptions = {}): PluginOption {
143
156
  client: {
144
157
  define: {
145
158
  'process.env.VITE_ENVIRONMENT': '"client"',
159
+ 'import.meta.env.VITE_ENVIRONMENT': '"client"',
146
160
  },
147
161
  },
148
162
 
149
163
  ssr: {
150
164
  define: {
151
165
  'process.env.VITE_ENVIRONMENT': '"ssr"',
166
+ 'import.meta.env.VITE_ENVIRONMENT': '"ssr"',
167
+ },
168
+ },
169
+
170
+ ios: {
171
+ define: {
172
+ 'process.env.VITE_ENVIRONMENT': '"ios"',
173
+ 'import.meta.env.VITE_ENVIRONMENT': '"ios"',
174
+ },
175
+ },
176
+
177
+ android: {
178
+ define: {
179
+ 'process.env.VITE_ENVIRONMENT': '"android"',
180
+ 'import.meta.env.VITE_ENVIRONMENT': '"android"',
152
181
  },
153
182
  },
154
183
  },
@@ -232,7 +261,7 @@ export function one(options: One.PluginOptions = {}): PluginOption {
232
261
  }),
233
262
 
234
263
  {
235
- name: 'define-app-key',
264
+ name: 'one-define-environment',
236
265
  config() {
237
266
  if (!options.app?.key) {
238
267
  return
@@ -240,14 +269,18 @@ export function one(options: One.PluginOptions = {}): PluginOption {
240
269
 
241
270
  return {
242
271
  define: {
243
- 'process.env.One_APP_NAME': JSON.stringify(options.app.key),
272
+ 'process.env.ONE_APP_NAME': JSON.stringify(options.app.key),
273
+ 'import.meta.env.ONE_APP_NAME': JSON.stringify(options.app.key),
274
+
275
+ 'process.env.ONE_CACHE_KEY': JSON.stringify(CACHE_KEY),
276
+ 'import.meta.env.ONE_CACHE_KEY': JSON.stringify(CACHE_KEY),
244
277
  },
245
278
  }
246
279
  },
247
280
  } satisfies Plugin,
248
281
 
249
282
  {
250
- name: 'use-react-18-for-native',
283
+ name: 'one-use-react-18-for-native',
251
284
  enforce: 'pre',
252
285
 
253
286
  async config() {
@@ -275,7 +308,7 @@ export function one(options: One.PluginOptions = {}): PluginOption {
275
308
  } satisfies Plugin,
276
309
 
277
310
  {
278
- name: 'optimize-deps-load-web-extensions',
311
+ name: 'one-optimize-deps-load-web-extensions',
279
312
  enforce: 'pre',
280
313
 
281
314
  applyToEnvironment(environment) {
@@ -10,9 +10,9 @@ const virtualEntryIdNativeName = `${virtualEntryIdName}-native`
10
10
  export const virtualEntryIdNative = `virtual:${virtualEntryIdNativeName}`
11
11
  const resolvedVirtualEntryIdNative = '\0' + virtualEntryIdNativeName
12
12
 
13
- const USE_One_SETUP_FILE = `
14
- if (process.env.One_SETUP_FILE) {
15
- import(/* @vite-ignore */ process.env.One_SETUP_FILE)
13
+ const USE_ONE_SETUP_FILE = `
14
+ if (process.env.ONE_SETUP_FILE) {
15
+ import(/* @vite-ignore */ process.env.ONE_SETUP_FILE)
16
16
  }
17
17
  `
18
18
 
@@ -36,7 +36,7 @@ export function createVirtualEntry(options: { root: string }): Plugin {
36
36
  if (id === resolvedVirtualEntryId) {
37
37
  const prependCode = isNativeEnvironment(this.environment)
38
38
  ? '' /* `import()` will not work on native */
39
- : USE_One_SETUP_FILE
39
+ : USE_ONE_SETUP_FILE
40
40
  return `
41
41
  ${prependCode}
42
42
 
@@ -52,7 +52,7 @@ export default createApp({
52
52
  if (id === resolvedVirtualEntryIdNative) {
53
53
  const prependCode = isNativeEnvironment(this.environment)
54
54
  ? '' /* `import()` will not work on native */
55
- : USE_One_SETUP_FILE
55
+ : USE_ONE_SETUP_FILE
56
56
  return `
57
57
  ${prependCode}
58
58
 
@@ -12,7 +12,7 @@ export function vitePluginSsrCss(pluginOpts: { entries: string[] }): Plugin {
12
12
  const virtualHref = '/@id/__x00__' + VIRTUAL_ENTRY
13
13
 
14
14
  return {
15
- name: `vite-plugin-ssr-css`,
15
+ name: `one-plugin-ssr-css`,
16
16
  apply: 'serve',
17
17
  configureServer(server_) {
18
18
  server = server_
@@ -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;QAAE,QAAQ,EAAE,SAAS,CAAA;KAAE,CAAC,CAAA;IACpD,wBAAwB,CAAC,EAAE,wBAAwB,GAAG;QACpD,KAAK,CAAC,EAAE;YACN,IAAI,EAAE,OAAO,CAAA;YACb,MAAM,EAAE;gBACN,OAAO,EAAE,MAAM,CAAA;gBACf,UAAU,EAAE,MAAM,CAAA;gBAClB,IAAI,EAAE,MAAM,CAAA;gBACZ,IAAI,EAAE,MAAM,CAAA;gBACZ,MAAM,EAAE,MAAM,CAAA;gBACd,YAAY,EAAE,MAAM,CAAA;aACrB,CAAA;SACF,CAAA;KACF,CAAA;CACF,CAAA;AAED,wBAAgB,IAAI,CAAC,KAAK,EAAE,SAAS,kDAmEpC"}
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;AAUvC,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;QAAE,QAAQ,EAAE,SAAS,CAAA;KAAE,CAAC,CAAA;IACpD,wBAAwB,CAAC,EAAE,wBAAwB,GAAG;QACpD,KAAK,CAAC,EAAE;YACN,IAAI,EAAE,OAAO,CAAA;YACb,MAAM,EAAE;gBACN,OAAO,EAAE,MAAM,CAAA;gBACf,UAAU,EAAE,MAAM,CAAA;gBAClB,IAAI,EAAE,MAAM,CAAA;gBACZ,IAAI,EAAE,MAAM,CAAA;gBACZ,MAAM,EAAE,MAAM,CAAA;gBACd,YAAY,EAAE,MAAM,CAAA;aACrB,CAAA;SACF,CAAA;KACF,CAAA;CACF,CAAA;AAED,wBAAgB,IAAI,CAAC,KAAK,EAAE,SAAS,kDAmEpC"}
@@ -1 +1 @@
1
- {"version":3,"file":"cleanUrl.d.ts","sourceRoot":"","sources":["../src/cleanUrl.ts"],"names":[],"mappings":"AAkBA,wBAAgB,cAAc,CAAC,WAAW,EAAE,MAAM,UAEjD;AAED,wBAAgB,aAAa,CAC3B,WAAW,EAAE,MAAM,EAEnB,UAAU,UAAW,UAWtB;AAED,wBAAgB,qBAAqB,CAAC,UAAU,EAAE,MAAM,UAKvD"}
1
+ {"version":3,"file":"cleanUrl.d.ts","sourceRoot":"","sources":["../src/cleanUrl.ts"],"names":[],"mappings":"AAqBA,wBAAgB,cAAc,CAAC,WAAW,EAAE,MAAM,UAEjD;AAED,wBAAgB,aAAa,CAC3B,WAAW,EAAE,MAAM,EAEnB,UAAU,UAAW,UAWtB;AAED,wBAAgB,qBAAqB,CAAC,UAAU,EAAE,MAAM,UAMvD"}
@@ -1,4 +1,8 @@
1
1
  export declare const isWebClient: boolean;
2
2
  export declare const isWebServer: boolean;
3
3
  export declare const isNative: boolean;
4
+ export declare const CACHE_KEY: string;
5
+ export declare const LOADER_JS_POSTFIX_UNCACHED = "_vxrn_loader.js";
6
+ export declare const LOADER_JS_POSTFIX: string;
7
+ export declare const PRELOAD_JS_POSTFIX: string;
4
8
  //# sourceMappingURL=constants.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,SAA2E,CAAA;AACnG,eAAO,MAAM,WAAW,SAA2E,CAAA;AACnG,eAAO,MAAM,QAAQ,SAA0C,CAAA"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,SAA2E,CAAA;AACnG,eAAO,MAAM,WAAW,SAA2E,CAAA;AACnG,eAAO,MAAM,QAAQ,SAA0C,CAAA;AAE/D,eAAO,MAAM,SAAS,QAA4E,CAAA;AAElG,eAAO,MAAM,0BAA0B,oBAAoB,CAAA;AAC3D,eAAO,MAAM,iBAAiB,QAA+C,CAAA;AAC7E,eAAO,MAAM,kBAAkB,QAA6B,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"createHandleRequest.d.ts","sourceRoot":"","sources":["../src/createHandleRequest.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAA;AAI9D,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,cAAc,CAAA;AAEvC,KAAK,mBAAmB,CAAC,eAAe,SAAS,MAAM,GAAG,EAAE,IAAI;IAC9D,OAAO,EAAE,OAAO,CAAA;IAChB,KAAK,EAAE,SAAS,CAAC,MAAM,CAAC,GAAG,eAAe,CAAA;IAC1C,GAAG,EAAE,GAAG,CAAA;IACR,WAAW,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;KAAE,CAAA;CAC5D,CAAA;AAED,KAAK,sBAAsB,GAAG,IAAI,GAAG,MAAM,GAAG,QAAQ,CAAA;AAEtD,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,GAAG,CAAC,aAAa,EAC1B,QAAQ,EAAE;IACR,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;IACxD,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;IAC3D,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;CACzD;;uBA4BgD,OAAO,KAAG,OAAO,CAAC,sBAAsB,CAAC;EAiJ3F"}
1
+ {"version":3,"file":"createHandleRequest.d.ts","sourceRoot":"","sources":["../src/createHandleRequest.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,+BAA+B,CAAA;AAI9D,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,cAAc,CAAA;AAEvC,KAAK,mBAAmB,CAAC,eAAe,SAAS,MAAM,GAAG,EAAE,IAAI;IAC9D,OAAO,EAAE,OAAO,CAAA;IAChB,KAAK,EAAE,SAAS,CAAC,MAAM,CAAC,GAAG,eAAe,CAAA;IAC1C,GAAG,EAAE,GAAG,CAAA;IACR,WAAW,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;KAAE,CAAA;CAC5D,CAAA;AAED,KAAK,sBAAsB,GAAG,IAAI,GAAG,MAAM,GAAG,QAAQ,CAAA;AAEtD,wBAAgB,mBAAmB,CACjC,OAAO,EAAE,GAAG,CAAC,aAAa,EAC1B,QAAQ,EAAE;IACR,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;IACxD,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;IAC3D,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,mBAAmB,KAAK,OAAO,CAAC,GAAG,CAAC,CAAA;CACzD;;uBA4BgD,OAAO,KAAG,OAAO,CAAC,sBAAsB,CAAC;EAsJ3F"}
@@ -1 +1 @@
1
- {"version":3,"file":"serve.d.ts","sourceRoot":"","sources":["../src/serve.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAA;AAK3B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,MAAM,CAAA;AAgBvC,wBAAsB,KAAK,CAAC,IAAI,GAAE,WAAW,CAAC,QAAQ,CAAM;mDAfJ,YAC9C;+CAER,YAAY;gDAED,YAAY;iDAElB,YAAW;+CAEW,YAAW;mDAGO,YAAY;GA6B1D"}
1
+ {"version":3,"file":"serve.d.ts","sourceRoot":"","sources":["../src/serve.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAA;AAK3B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,MAAM,CAAA;AAgBvC,wBAAsB,KAAK,CAAC,IAAI,GAAE,WAAW,CAAC,QAAQ,CAAM;mDAfJ,YACvD;+CAC+C,YAChD;gDAEK,YAAY;iDAEV,YAAY;+CAEX,YAAY;mDAGkB,YAAY;GA+BjD"}
@@ -1 +1 @@
1
- {"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../src/vite/build.ts"],"names":[],"mappings":"AA6BA,wBAAsB,KAAK,CAAC,IAAI,EAAE;IAChC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,MAAM,CAAA;CACd,iBAsgBA"}
1
+ {"version":3,"file":"build.d.ts","sourceRoot":"","sources":["../../src/vite/build.ts"],"names":[],"mappings":"AA6BA,wBAAsB,KAAK,CAAC,IAAI,EAAE;IAChC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,IAAI,CAAC,EAAE,MAAM,CAAA;CACd,iBAugBA"}
@@ -1 +1 @@
1
- {"version":3,"file":"one.d.ts","sourceRoot":"","sources":["../../src/vite/one.ts"],"names":[],"mappings":"AAEA,OAAO,EAAe,KAAK,YAAY,EAAuC,MAAM,MAAM,CAAA;AAG1F,OAAO,qBAAqB,CAAA;AAS5B,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,SAAS,CAAA;AASlC,wBAAgB,GAAG,CAAC,OAAO,GAAE,GAAG,CAAC,aAAkB,GAAG,YAAY,CA+RjE;AAeD,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,8BAalE"}
1
+ {"version":3,"file":"one.d.ts","sourceRoot":"","sources":["../../src/vite/one.ts"],"names":[],"mappings":"AAGA,OAAO,EAAe,KAAK,YAAY,EAAuC,MAAM,MAAM,CAAA;AAI1F,OAAO,qBAAqB,CAAA;AAO5B,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,SAAS,CAAA;AASlC,wBAAgB,GAAG,CAAC,OAAO,GAAE,GAAG,CAAC,aAAkB,GAAG,YAAY,CAgUjE;AAeD,wBAAsB,kBAAkB,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,8BAalE"}
@@ -1,26 +0,0 @@
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 constants_exports = {};
22
- __export(constants_exports, {
23
- CACHE_KEY: () => CACHE_KEY
24
- });
25
- module.exports = __toCommonJS(constants_exports);
26
- const CACHE_KEY = `${Math.random()}`.slice(3);
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/router/constants.ts"],
4
- "mappings": ";;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAGO,MAAM,YAAY,GAAG,KAAK,OAAO,CAAC,GAAG,MAAM,CAAC;",
5
- "names": []
6
- }
@@ -1,26 +0,0 @@
1
- "use strict";
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __hasOwnProp = Object.prototype.hasOwnProperty;
6
- var __export = (target, all) => {
7
- for (var name in all)
8
- __defProp(target, name, { get: all[name], enumerable: !0 });
9
- }, __copyProps = (to, from, except, desc) => {
10
- if (from && typeof from == "object" || typeof from == "function")
11
- for (let key of __getOwnPropNames(from))
12
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
13
- return to;
14
- };
15
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
16
- var constants_exports = {};
17
- __export(constants_exports, {
18
- CACHE_KEY: () => CACHE_KEY
19
- });
20
- module.exports = __toCommonJS(constants_exports);
21
- var CACHE_KEY = `${Math.random()}`.slice(3);
22
- // Annotate the CommonJS export names for ESM import in node:
23
- 0 && (module.exports = {
24
- CACHE_KEY
25
- });
26
- //# sourceMappingURL=constants.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/router/Users/n8/one/packages/one/src/router/constants.ts"],
4
- "mappings": ";;;;;;;;;;;;;;;AAAA;;;;;AAGO,IAAMA,YAAY,GAAGC,KAAKC,OAAM,CAAA,GAAKC,MAAM,CAAA;",
5
- "names": ["CACHE_KEY", "Math", "random", "slice"]
6
- }
@@ -1,47 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf,
6
- __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: !0
11
- });
12
- },
13
- __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
15
- get: () => from[key],
16
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
17
- });
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
26
- value: mod,
27
- enumerable: !0
28
- }) : target, mod)),
29
- __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
30
- value: !0
31
- }), mod);
32
- var loadEnv_exports = {};
33
- __export(loadEnv_exports, {
34
- loadEnv: () => loadEnv
35
- });
36
- module.exports = __toCommonJS(loadEnv_exports);
37
- var import_node_fs = __toESM(require("node:fs"), 1),
38
- import_node_path = __toESM(require("node:path"), 1);
39
- async function loadEnv(root) {
40
- const envPath = import_node_path.default.join(root, ".env");
41
- if (!import_node_fs.default.existsSync(envPath)) return;
42
- const result = (await import("dotenv")).config({
43
- path: envPath
44
- });
45
- if (result.error) throw result.error;
46
- return !0;
47
- }
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/vite/loadEnv.ts"],
4
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,qBAAe,gCACf,mBAAiB;AAEjB,eAAsB,QAAQ,MAAc;AAC1C,QAAM,UAAU,iBAAAA,QAAK,KAAK,MAAM,MAAM;AACtC,MAAI,CAAC,eAAAC,QAAG,WAAW,OAAO,EAAG;AAE7B,QAAM,UADS,MAAM,OAAO,QAAQ,GACd,OAAO,EAAE,MAAM,QAAQ,CAAC;AAC9C,MAAI,OAAO,MAAO,OAAM,OAAO;AAC/B,SAAO;AACT;",
5
- "names": ["path", "fs"]
6
- }
@@ -1,44 +0,0 @@
1
- "use strict";
2
- var __create = Object.create;
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all)
9
- __defProp(target, name, { get: all[name], enumerable: !0 });
10
- }, __copyProps = (to, from, except, desc) => {
11
- if (from && typeof from == "object" || typeof from == "function")
12
- for (let key of __getOwnPropNames(from))
13
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
- return to;
15
- };
16
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
17
- // If the importer is in node compatibility mode or this is not an ESM
18
- // file that has been converted to a CommonJS file using a Babel-
19
- // compatible transform (i.e. "__esModule" has not been set), then set
20
- // "default" to the CommonJS "module.exports" for node compatibility.
21
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
22
- mod
23
- )), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
24
- var loadEnv_exports = {};
25
- __export(loadEnv_exports, {
26
- loadEnv: () => loadEnv
27
- });
28
- module.exports = __toCommonJS(loadEnv_exports);
29
- var import_node_fs = __toESM(require("node:fs"), 1), import_node_path = __toESM(require("node:path"), 1);
30
- async function loadEnv(root) {
31
- var envPath = import_node_path.default.join(root, ".env");
32
- if (import_node_fs.default.existsSync(envPath)) {
33
- var dotenv = await import("dotenv"), result = dotenv.config({
34
- path: envPath
35
- });
36
- if (result.error) throw result.error;
37
- return !0;
38
- }
39
- }
40
- // Annotate the CommonJS export names for ESM import in node:
41
- 0 && (module.exports = {
42
- loadEnv
43
- });
44
- //# sourceMappingURL=loadEnv.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/vite/Users/n8/one/packages/one/src/vite/loadEnv.ts"],
4
- "mappings": ";;;;;;;;;;;;;;;;;;;;;;;AAAA;;;;;qBAAe,gCACf,mBAAiB;AAEjB,eAAsBA,QAAQC,MAAY;AACxC,MAAMC,UAAUC,iBAAAA,QAAKC,KAAKH,MAAM,MAAA;AAChC,MAAKI,eAAAA,QAAGC,WAAWJ,OAAAA,GACnB;QAAMK,SAAS,MAAM,OAAO,QAAA,GACtBC,SAASD,OAAOE,OAAO;MAAEN,MAAMD;IAAQ,CAAA;AAC7C,QAAIM,OAAOE,MAAO,OAAMF,OAAOE;AAC/B,WAAO;;AACT;",
5
- "names": ["loadEnv", "root", "envPath", "path", "join", "fs", "existsSync", "dotenv", "result", "config", "error"]
6
- }
@@ -1,5 +0,0 @@
1
- const CACHE_KEY = `${Math.random()}`.slice(3);
2
- export {
3
- CACHE_KEY
4
- };
5
- //# sourceMappingURL=constants.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/router/constants.ts"],
4
- "mappings": "AAGO,MAAM,YAAY,GAAG,KAAK,OAAO,CAAC,GAAG,MAAM,CAAC;",
5
- "names": []
6
- }
@@ -1,3 +0,0 @@
1
- const CACHE_KEY = `${Math.random()}`.slice(3);
2
- export { CACHE_KEY };
3
- //# sourceMappingURL=constants.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["CACHE_KEY","Math","random","slice"],"sources":["../../../src/router/constants.ts"],"sourcesContent":[null],"mappings":"AAGO,MAAMA,SAAA,GAAY,GAAGC,IAAA,CAAKC,MAAA,CAAO,CAAC,GAAGC,KAAA,CAAM,CAAC","ignoreList":[]}
@@ -1,5 +0,0 @@
1
- var CACHE_KEY = `${Math.random()}`.slice(3);
2
- export {
3
- CACHE_KEY
4
- };
5
- //# sourceMappingURL=constants.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/router/Users/n8/one/packages/one/src/router/constants.ts"],
4
- "mappings": "AAGO,IAAMA,YAAY,GAAGC,KAAKC,OAAM,CAAA,GAAKC,MAAM,CAAA;",
5
- "names": ["CACHE_KEY", "Math", "random", "slice"]
6
- }
@@ -1,13 +0,0 @@
1
- import fs from "node:fs";
2
- import path from "node:path";
3
- async function loadEnv(root) {
4
- const envPath = path.join(root, ".env");
5
- if (!fs.existsSync(envPath)) return;
6
- const result = (await import("dotenv")).config({ path: envPath });
7
- if (result.error) throw result.error;
8
- return !0;
9
- }
10
- export {
11
- loadEnv
12
- };
13
- //# sourceMappingURL=loadEnv.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/vite/loadEnv.ts"],
4
- "mappings": "AAAA,OAAO,QAAQ;AACf,OAAO,UAAU;AAEjB,eAAsB,QAAQ,MAAc;AAC1C,QAAM,UAAU,KAAK,KAAK,MAAM,MAAM;AACtC,MAAI,CAAC,GAAG,WAAW,OAAO,EAAG;AAE7B,QAAM,UADS,MAAM,OAAO,QAAQ,GACd,OAAO,EAAE,MAAM,QAAQ,CAAC;AAC9C,MAAI,OAAO,MAAO,OAAM,OAAO;AAC/B,SAAO;AACT;",
5
- "names": []
6
- }
@@ -1,13 +0,0 @@
1
- import fs from "node:fs";
2
- import path from "node:path";
3
- async function loadEnv(root) {
4
- const envPath = path.join(root, ".env");
5
- if (!fs.existsSync(envPath)) return;
6
- const result = (await import("dotenv")).config({
7
- path: envPath
8
- });
9
- if (result.error) throw result.error;
10
- return !0;
11
- }
12
- export { loadEnv };
13
- //# sourceMappingURL=loadEnv.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["fs","path","loadEnv","root","envPath","join","existsSync","result","config","error"],"sources":["../../../src/vite/loadEnv.ts"],"sourcesContent":[null],"mappings":"AAAA,OAAOA,EAAA,MAAQ;AACf,OAAOC,IAAA,MAAU;AAEjB,eAAsBC,QAAQC,IAAA,EAAc;EAC1C,MAAMC,OAAA,GAAUH,IAAA,CAAKI,IAAA,CAAKF,IAAA,EAAM,MAAM;EACtC,IAAI,CAACH,EAAA,CAAGM,UAAA,CAAWF,OAAO,GAAG;EAE7B,MAAMG,MAAA,IADS,MAAM,OAAO,QAAQ,GACdC,MAAA,CAAO;IAAEP,IAAA,EAAMG;EAAQ,CAAC;EAC9C,IAAIG,MAAA,CAAOE,KAAA,EAAO,MAAMF,MAAA,CAAOE,KAAA;EAC/B,OAAO;AACT","ignoreList":[]}
@@ -1,16 +0,0 @@
1
- import fs from "node:fs";
2
- import path from "node:path";
3
- async function loadEnv(root) {
4
- var envPath = path.join(root, ".env");
5
- if (fs.existsSync(envPath)) {
6
- var dotenv = await import("dotenv"), result = dotenv.config({
7
- path: envPath
8
- });
9
- if (result.error) throw result.error;
10
- return !0;
11
- }
12
- }
13
- export {
14
- loadEnv
15
- };
16
- //# sourceMappingURL=loadEnv.js.map
@@ -1,6 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../src/vite/Users/n8/one/packages/one/src/vite/loadEnv.ts"],
4
- "mappings": "AAAA,OAAOA,QAAQ;AACf,OAAOC,UAAU;AAEjB,eAAsBC,QAAQC,MAAY;AACxC,MAAMC,UAAUH,KAAKI,KAAKF,MAAM,MAAA;AAChC,MAAKH,GAAGM,WAAWF,OAAAA,GACnB;QAAMG,SAAS,MAAM,OAAO,QAAA,GACtBC,SAASD,OAAOE,OAAO;MAAER,MAAMG;IAAQ,CAAA;AAC7C,QAAII,OAAOE,MAAO,OAAMF,OAAOE;AAC/B,WAAO;;AACT;",
5
- "names": ["fs", "path", "loadEnv", "root", "envPath", "join", "existsSync", "dotenv", "result", "config", "error"]
6
- }
@@ -1,4 +0,0 @@
1
- // for example we have loaders like _vxrn_loader.js safari caches things
2
- // aggressively so we want to have a search params that clears that cache
3
- // uniquely across deploys this will be unique per-deploy nicely:
4
- export const CACHE_KEY = `${Math.random()}`.slice(3)
@@ -1,11 +0,0 @@
1
- import fs from 'node:fs'
2
- import path from 'node:path'
3
-
4
- export async function loadEnv(root: string) {
5
- const envPath = path.join(root, '.env')
6
- if (!fs.existsSync(envPath)) return
7
- const dotenv = await import('dotenv')
8
- const result = dotenv.config({ path: envPath })
9
- if (result.error) throw result.error
10
- return true
11
- }
@@ -1,2 +0,0 @@
1
- export declare const CACHE_KEY: string;
2
- //# sourceMappingURL=constants.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../src/router/constants.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,SAAS,QAA8B,CAAA"}
@@ -1,2 +0,0 @@
1
- export declare function loadEnv(root: string): Promise<true | undefined>;
2
- //# sourceMappingURL=loadEnv.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"loadEnv.d.ts","sourceRoot":"","sources":["../../src/vite/loadEnv.ts"],"names":[],"mappings":"AAGA,wBAAsB,OAAO,CAAC,IAAI,EAAE,MAAM,6BAOzC"}