vike 0.4.181-commit-1ff0c6d → 0.4.182-commit-4405294
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/node/plugin/plugins/devConfig/index.js +5 -0
- package/dist/cjs/node/plugin/plugins/importUserCode/v1-design/getVikeConfig.js +3 -3
- package/dist/cjs/utils/PROJECT_VERSION.js +1 -1
- package/dist/cjs/utils/assertSingleInstance.js +3 -3
- package/dist/esm/client/shared/getPageContextProxyForUser.js +2 -1
- package/dist/esm/node/plugin/plugins/devConfig/index.js +5 -0
- package/dist/esm/node/plugin/plugins/importUserCode/v1-design/getVikeConfig.js +3 -3
- package/dist/esm/utils/PROJECT_VERSION.d.ts +1 -1
- package/dist/esm/utils/PROJECT_VERSION.js +1 -1
- package/dist/esm/utils/assertSingleInstance.js +3 -3
- package/dist/esm/utils/projectInfo.d.ts +1 -1
- package/package.json +4 -8
|
@@ -29,7 +29,12 @@ function devConfig() {
|
|
|
29
29
|
// We exclude Vike's client runtime to be able to use Vite's import.meta.glob()
|
|
30
30
|
'vike/client',
|
|
31
31
|
'vike/client/router',
|
|
32
|
+
// It seems like client-side/isomorphic imports also need to be excluded, in order to avoid the following:
|
|
33
|
+
// ```
|
|
34
|
+
// Client runtime loaded twice https://vike.dev/client-runtime-duplicated
|
|
35
|
+
// ```
|
|
32
36
|
'vike/routing',
|
|
37
|
+
'vike/getPageContext',
|
|
33
38
|
// We exclude @brillout/json-serializer and @brillout/picocolors to avoid:
|
|
34
39
|
// ```
|
|
35
40
|
// 9:28:58 AM [vite] ✨ new dependencies optimized: @brillout/json-serializer/parse
|
|
@@ -327,10 +327,10 @@ function assertUsageGlobalConfigs(interfaceFilesRelevantList, configDefinitions,
|
|
|
327
327
|
});
|
|
328
328
|
});
|
|
329
329
|
(0, utils_js_1.assertUsage)(false, [
|
|
330
|
-
`${interfaceFile.filePath.filePathToShowToUser}
|
|
330
|
+
`${interfaceFile.filePath.filePathToShowToUser} sets the config ${picocolors_1.default.cyan(configName)} but it's a global config:`,
|
|
331
331
|
configFilesGlobal.length > 0
|
|
332
|
-
? `define ${picocolors_1.default.cyan(configName)} at ${(0, utils_js_1.joinEnglish)(configFilesGlobal, 'or')} instead
|
|
333
|
-
: `create a global config (e.g. /pages/+config.js) and define ${picocolors_1.default.cyan(configName)} there instead
|
|
332
|
+
? `define ${picocolors_1.default.cyan(configName)} at ${(0, utils_js_1.joinEnglish)(configFilesGlobal, 'or')} instead.`
|
|
333
|
+
: `create a global config (e.g. /pages/+config.js) and define ${picocolors_1.default.cyan(configName)} there instead.`
|
|
334
334
|
].join(' '));
|
|
335
335
|
}
|
|
336
336
|
}
|
|
@@ -14,12 +14,12 @@ const picocolors_1 = __importDefault(require("@brillout/picocolors"));
|
|
|
14
14
|
/* Use original assertUsage() & assertWarning() after all CJS is removed from node_modules/vike/dist/
|
|
15
15
|
import { assertUsage, assertWarning } from './assert.js'
|
|
16
16
|
*/
|
|
17
|
-
const globalObject = (0, getGlobalObject_js_1.getGlobalObject)('
|
|
17
|
+
const globalObject = (0, getGlobalObject_js_1.getGlobalObject)('assertSingleInstance.ts', {
|
|
18
18
|
instances: [],
|
|
19
19
|
alreadyLogged: new Set()
|
|
20
20
|
});
|
|
21
|
-
const clientRuntimesClonflict =
|
|
22
|
-
const clientNotSingleInstance =
|
|
21
|
+
const clientRuntimesClonflict = 'Client runtime of both Server Routing and Client Routing loaded https://vike.dev/client-runtimes-conflict';
|
|
22
|
+
const clientNotSingleInstance = 'Client runtime loaded twice https://vike.dev/client-runtime-duplicated';
|
|
23
23
|
function assertSingleInstance() {
|
|
24
24
|
{
|
|
25
25
|
const versions = (0, unique_js_1.unique)(globalObject.instances);
|
|
@@ -27,7 +27,12 @@ function devConfig() {
|
|
|
27
27
|
// We exclude Vike's client runtime to be able to use Vite's import.meta.glob()
|
|
28
28
|
'vike/client',
|
|
29
29
|
'vike/client/router',
|
|
30
|
+
// It seems like client-side/isomorphic imports also need to be excluded, in order to avoid the following:
|
|
31
|
+
// ```
|
|
32
|
+
// Client runtime loaded twice https://vike.dev/client-runtime-duplicated
|
|
33
|
+
// ```
|
|
30
34
|
'vike/routing',
|
|
35
|
+
'vike/getPageContext',
|
|
31
36
|
// We exclude @brillout/json-serializer and @brillout/picocolors to avoid:
|
|
32
37
|
// ```
|
|
33
38
|
// 9:28:58 AM [vite] ✨ new dependencies optimized: @brillout/json-serializer/parse
|
|
@@ -323,10 +323,10 @@ function assertUsageGlobalConfigs(interfaceFilesRelevantList, configDefinitions,
|
|
|
323
323
|
});
|
|
324
324
|
});
|
|
325
325
|
assertUsage(false, [
|
|
326
|
-
`${interfaceFile.filePath.filePathToShowToUser}
|
|
326
|
+
`${interfaceFile.filePath.filePathToShowToUser} sets the config ${pc.cyan(configName)} but it's a global config:`,
|
|
327
327
|
configFilesGlobal.length > 0
|
|
328
|
-
? `define ${pc.cyan(configName)} at ${joinEnglish(configFilesGlobal, 'or')} instead
|
|
329
|
-
: `create a global config (e.g. /pages/+config.js) and define ${pc.cyan(configName)} there instead
|
|
328
|
+
? `define ${pc.cyan(configName)} at ${joinEnglish(configFilesGlobal, 'or')} instead.`
|
|
329
|
+
: `create a global config (e.g. /pages/+config.js) and define ${pc.cyan(configName)} there instead.`
|
|
330
330
|
].join(' '));
|
|
331
331
|
}
|
|
332
332
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const PROJECT_VERSION: "0.4.
|
|
1
|
+
export declare const PROJECT_VERSION: "0.4.182-commit-4405294";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Automatically updated by @brillout/release-me
|
|
2
|
-
export const PROJECT_VERSION = '0.4.
|
|
2
|
+
export const PROJECT_VERSION = '0.4.182-commit-4405294';
|
|
@@ -11,12 +11,12 @@ import pc from '@brillout/picocolors';
|
|
|
11
11
|
/* Use original assertUsage() & assertWarning() after all CJS is removed from node_modules/vike/dist/
|
|
12
12
|
import { assertUsage, assertWarning } from './assert.js'
|
|
13
13
|
*/
|
|
14
|
-
const globalObject = getGlobalObject('
|
|
14
|
+
const globalObject = getGlobalObject('assertSingleInstance.ts', {
|
|
15
15
|
instances: [],
|
|
16
16
|
alreadyLogged: new Set()
|
|
17
17
|
});
|
|
18
|
-
const clientRuntimesClonflict =
|
|
19
|
-
const clientNotSingleInstance =
|
|
18
|
+
const clientRuntimesClonflict = 'Client runtime of both Server Routing and Client Routing loaded https://vike.dev/client-runtimes-conflict';
|
|
19
|
+
const clientNotSingleInstance = 'Client runtime loaded twice https://vike.dev/client-runtime-duplicated';
|
|
20
20
|
function assertSingleInstance() {
|
|
21
21
|
{
|
|
22
22
|
const versions = unique(globalObject.instances);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "vike",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.182-commit-4405294",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"dev": "tsc --watch",
|
|
6
6
|
"build": "rimraf dist/ && pnpm run build:esm && pnpm run build:cjs",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"es-module-lexer": "^1.0.0",
|
|
24
24
|
"esbuild": "^0.19.0",
|
|
25
25
|
"fast-glob": "^3.0.0",
|
|
26
|
-
"semver": "^7.
|
|
26
|
+
"semver": "^7.0.0",
|
|
27
27
|
"sirv": "^2.0.0",
|
|
28
28
|
"source-map-support": "^0.5.0"
|
|
29
29
|
},
|
|
@@ -208,12 +208,7 @@
|
|
|
208
208
|
},
|
|
209
209
|
"devDependencies": {
|
|
210
210
|
"@biomejs/biome": "^1.5.3",
|
|
211
|
-
"@brillout/import": "^0.2.3",
|
|
212
|
-
"@brillout/json-serializer": "^0.5.8",
|
|
213
|
-
"@brillout/picocolors": "^1.0.13",
|
|
214
211
|
"@brillout/release-me": "^0.4.0",
|
|
215
|
-
"@brillout/require-shim": "^0.1.2",
|
|
216
|
-
"@brillout/vite-plugin-server-entry": "^0.4.0",
|
|
217
212
|
"@types/estree": "^1.0.5",
|
|
218
213
|
"@types/jest": "^29.5.11",
|
|
219
214
|
"@types/node": "^20.10.5",
|
|
@@ -226,10 +221,11 @@
|
|
|
226
221
|
"fast-glob": "^3.3.2",
|
|
227
222
|
"react-streaming": "^0.3.42",
|
|
228
223
|
"rimraf": "^5.0.5",
|
|
224
|
+
"semver": "^7.6.3",
|
|
229
225
|
"sirv": "^2.0.4",
|
|
230
226
|
"source-map-support": "^0.5.21",
|
|
231
227
|
"typescript": "^5.4.5",
|
|
232
|
-
"vite": "^5.
|
|
228
|
+
"vite": "^5.4.0"
|
|
233
229
|
},
|
|
234
230
|
"engines": {
|
|
235
231
|
"node": ">=18.0.0"
|