@nuxt/kit-nightly 4.1.4-29331062.94e6fbb7 → 4.1.4-29331135.2311b272
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/index.mjs +14 -30
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -843,19 +843,20 @@ async function loadNuxtConfig(opts) {
|
|
|
843
843
|
cwd: opts.cwd || process.cwd()
|
|
844
844
|
})).map((d) => d.endsWith("/") ? d.substring(0, d.length - 1) : d).sort((a, b) => b.localeCompare(a));
|
|
845
845
|
opts.overrides = defu$1(opts.overrides, { _extends: localLayers });
|
|
846
|
-
const
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
);
|
|
846
|
+
const globalSelf = globalThis;
|
|
847
|
+
globalSelf.defineNuxtConfig = (c) => c;
|
|
848
|
+
const { configFile, layers = [], cwd, config: nuxtConfig, meta } = await loadConfig({
|
|
849
|
+
name: "nuxt",
|
|
850
|
+
configFile: "nuxt.config",
|
|
851
|
+
rcFile: ".nuxtrc",
|
|
852
|
+
extend: { extendKey: ["theme", "_extends", "extends"] },
|
|
853
|
+
dotenv: true,
|
|
854
|
+
globalRc: true,
|
|
855
|
+
// @ts-expect-error TODO: fix type in c12, it should accept createDefu directly
|
|
856
|
+
merger,
|
|
857
|
+
...opts
|
|
858
|
+
});
|
|
859
|
+
delete globalSelf.defineNuxtConfig;
|
|
859
860
|
nuxtConfig.rootDir ||= cwd;
|
|
860
861
|
nuxtConfig._nuxtConfigFile = configFile;
|
|
861
862
|
nuxtConfig._nuxtConfigFiles = [configFile];
|
|
@@ -923,23 +924,6 @@ async function loadNuxtSchema(cwd) {
|
|
|
923
924
|
const schemaPath = resolveModuleURL("@nuxt/schema", { try: true, from: urls }) ?? "@nuxt/schema";
|
|
924
925
|
return await import(schemaPath).then((r) => r.NuxtConfigSchema);
|
|
925
926
|
}
|
|
926
|
-
async function withDefineNuxtConfig(fn) {
|
|
927
|
-
const key = "defineNuxtConfig";
|
|
928
|
-
const globalSelf = globalThis;
|
|
929
|
-
if (!globalSelf[key]) {
|
|
930
|
-
globalSelf[key] = (c) => c;
|
|
931
|
-
globalSelf[key].count = 0;
|
|
932
|
-
}
|
|
933
|
-
globalSelf[key].count++;
|
|
934
|
-
try {
|
|
935
|
-
return await fn();
|
|
936
|
-
} finally {
|
|
937
|
-
globalSelf[key].count--;
|
|
938
|
-
if (!globalSelf[key].count) {
|
|
939
|
-
delete globalSelf[key];
|
|
940
|
-
}
|
|
941
|
-
}
|
|
942
|
-
}
|
|
943
927
|
|
|
944
928
|
function extendNuxtSchema(def) {
|
|
945
929
|
const nuxt = useNuxt();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/kit-nightly",
|
|
3
|
-
"version": "4.1.4-
|
|
3
|
+
"version": "4.1.4-29331135.2311b272",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/nuxt/nuxt.git",
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"untyped": "^2.0.0"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
|
-
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.1.4-
|
|
50
|
+
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.1.4-29331135.2311b272",
|
|
51
51
|
"@rspack/core": "1.5.8",
|
|
52
52
|
"@types/semver": "7.7.1",
|
|
53
53
|
"hookable": "5.5.3",
|