nuxt-nightly 4.3.0-29430640.29b20b87 → 4.3.0-29431381.f1713850
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/app.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './dist/app/index'
|
|
1
|
+
export * from './dist/app/index.ts'
|
|
@@ -6,7 +6,7 @@ import { navigateTo, resolveRouteObject, useRouter } from "../composables/router
|
|
|
6
6
|
import { useNuxtApp, useRuntimeConfig } from "../nuxt.js";
|
|
7
7
|
import { cancelIdleCallback, requestIdleCallback } from "../compat/idle-callback.js";
|
|
8
8
|
import { nuxtLinkDefaults } from "#build/nuxt.config.mjs";
|
|
9
|
-
import { hashMode } from "#build/router.options";
|
|
9
|
+
import { hashMode } from "#build/router.options.mjs";
|
|
10
10
|
const firstNonUndefined = (...args) => args.find((arg) => arg !== void 0);
|
|
11
11
|
const NuxtLinkDevKeySymbol = Symbol("nuxt-link-dev-key");
|
|
12
12
|
// @__NO_SIDE_EFFECTS__
|
package/dist/index.mjs
CHANGED
|
@@ -9,14 +9,14 @@ import ignore from 'ignore';
|
|
|
9
9
|
import { useLogger, tryUseNuxt, useNuxt, directoryToURL, getLayerDirectories, resolveFiles, resolvePath, defineNuxtModule, findPath, addPlugin, addTemplate, addTypeTemplate, addComponent, useNitro, addBuildPlugin, isIgnored, resolveAlias as resolveAlias$1, addPluginTemplate, addImportsSources, addVitePlugin, createIsIgnored, updateTemplates, tryResolveModule, normalizeModuleTranspilePath, importModule, createResolver, tryImportModule, runWithNuxtContext, nuxtCtx, loadNuxtConfig, addWebpackPlugin, installModules, resolveIgnorePatterns, addRouteMiddleware, resolveModuleWithOptions, normalizeTemplate, normalizePlugin } from '@nuxt/kit';
|
|
10
10
|
import { resolvePackageJSON, readPackage, readPackageJSON } from 'pkg-types';
|
|
11
11
|
import { hash, isEqual, serialize } from 'ohash';
|
|
12
|
-
import
|
|
12
|
+
import { consola } from 'consola';
|
|
13
13
|
import onChange from 'on-change';
|
|
14
14
|
import { colors } from 'consola/utils';
|
|
15
15
|
import { resolveCompatibilityDatesFromEnv, formatDate } from 'compatx';
|
|
16
16
|
import escapeRE from 'escape-string-regexp';
|
|
17
17
|
import { withTrailingSlash as withTrailingSlash$1, parseURL, parseQuery, joinURL, withLeadingSlash, encodePath, withoutLeadingSlash } from 'ufo';
|
|
18
18
|
import { ImpoundPlugin } from 'impound';
|
|
19
|
-
import
|
|
19
|
+
import { defu } from 'defu';
|
|
20
20
|
import { satisfies, coerce } from 'semver';
|
|
21
21
|
import { isCI, provider, hasTTY } from 'std-env';
|
|
22
22
|
import { genArrayFromRaw, genSafeVariableName, genImport, genDynamicImport, genObjectFromRawEntries, genString, genDynamicTypeImport, genExport } from 'knitwork';
|
|
@@ -3837,7 +3837,9 @@ function addDeclarationTemplates(ctx, options) {
|
|
|
3837
3837
|
});
|
|
3838
3838
|
}
|
|
3839
3839
|
|
|
3840
|
-
const version = "4.3.0-
|
|
3840
|
+
const version = "4.3.0-29431381.f1713850";
|
|
3841
|
+
const pkg = {
|
|
3842
|
+
version: version};
|
|
3841
3843
|
|
|
3842
3844
|
function createImportProtectionPatterns(nuxt, options) {
|
|
3843
3845
|
const patterns = [];
|
|
@@ -5000,7 +5002,7 @@ function createNuxt(options) {
|
|
|
5000
5002
|
hooks.callHookWith = (...args) => runWithNuxtContext(nuxt, () => callHookWith(...args));
|
|
5001
5003
|
const nuxt = {
|
|
5002
5004
|
__name: randomUUID(),
|
|
5003
|
-
_version: version,
|
|
5005
|
+
_version: pkg.version,
|
|
5004
5006
|
_asyncLocalStorageModule: options.experimental.debugModuleMutation ? new AsyncLocalStorage() : void 0,
|
|
5005
5007
|
hooks,
|
|
5006
5008
|
callHook: hooks.callHook,
|
|
@@ -5129,7 +5131,7 @@ Using \`${fallbackCompatibilityDate}\` as fallback. More info at: ${colors.under
|
|
|
5129
5131
|
let paths;
|
|
5130
5132
|
nuxt.hook("nitro:config", async (nitroConfig) => {
|
|
5131
5133
|
paths ||= await resolveTypescriptPaths(nuxt);
|
|
5132
|
-
nitroConfig.typescript = defu
|
|
5134
|
+
nitroConfig.typescript = defu(nitroConfig.typescript, {
|
|
5133
5135
|
tsConfig: { compilerOptions: { paths: { ...paths } } }
|
|
5134
5136
|
});
|
|
5135
5137
|
});
|
|
@@ -5158,9 +5160,9 @@ Using \`${fallbackCompatibilityDate}\` as fallback. More info at: ${colors.under
|
|
|
5158
5160
|
opts.sharedReferences.push({ path: resolve(nuxt.options.buildDir, "types/runtime-config.d.ts") });
|
|
5159
5161
|
opts.sharedReferences.push({ path: resolve(nuxt.options.buildDir, "types/app.config.d.ts") });
|
|
5160
5162
|
paths ||= await resolveTypescriptPaths(nuxt);
|
|
5161
|
-
opts.tsConfig.compilerOptions = defu
|
|
5162
|
-
opts.nodeTsConfig.compilerOptions = defu
|
|
5163
|
-
opts.sharedTsConfig.compilerOptions = defu
|
|
5163
|
+
opts.tsConfig.compilerOptions = defu(opts.tsConfig.compilerOptions, { paths: { ...paths } });
|
|
5164
|
+
opts.nodeTsConfig.compilerOptions = defu(opts.nodeTsConfig.compilerOptions, { paths: { ...paths } });
|
|
5165
|
+
opts.sharedTsConfig.compilerOptions = defu(opts.sharedTsConfig.compilerOptions, { paths: { ...paths } });
|
|
5164
5166
|
for (const dirs of layerDirs) {
|
|
5165
5167
|
const declaration = join(dirs.root, "index.d.ts");
|
|
5166
5168
|
if (existsSync(declaration)) {
|
|
@@ -5529,7 +5531,7 @@ async function loadNuxt(opts) {
|
|
|
5529
5531
|
}
|
|
5530
5532
|
}
|
|
5531
5533
|
if (!options._modules.some((m) => m === "@nuxt/scripts" || m === "@nuxt/scripts-nightly")) {
|
|
5532
|
-
options.imports = defu
|
|
5534
|
+
options.imports = defu(options.imports, {
|
|
5533
5535
|
presets: [scriptsStubsPreset]
|
|
5534
5536
|
});
|
|
5535
5537
|
}
|
|
@@ -5692,8 +5694,8 @@ async function resolveModules(nuxt) {
|
|
|
5692
5694
|
const NESTED_PKG_RE = /^[^@]+\//;
|
|
5693
5695
|
async function resolveTypescriptPaths(nuxt) {
|
|
5694
5696
|
nuxt.options.typescript.hoist ||= [];
|
|
5695
|
-
const paths = Object.fromEntries(await Promise.all(nuxt.options.typescript.hoist.map(async (
|
|
5696
|
-
const [_pkg =
|
|
5697
|
+
const paths = Object.fromEntries(await Promise.all(nuxt.options.typescript.hoist.map(async (pkg2) => {
|
|
5698
|
+
const [_pkg = pkg2, _subpath] = NESTED_PKG_RE.test(pkg2) ? pkg2.split("/") : [pkg2];
|
|
5697
5699
|
const subpath = _subpath ? "/" + _subpath : "";
|
|
5698
5700
|
if (nuxt._dependencies?.has(_pkg) && !(_pkg in nightlies)) {
|
|
5699
5701
|
return [];
|
|
@@ -5702,12 +5704,12 @@ async function resolveTypescriptPaths(nuxt) {
|
|
|
5702
5704
|
const nightly = nightlies[_pkg];
|
|
5703
5705
|
const path2 = await resolveTypePath(nightly + subpath, subpath, nuxt.options.modulesDir);
|
|
5704
5706
|
if (path2) {
|
|
5705
|
-
return [[
|
|
5707
|
+
return [[pkg2, [path2]], [nightly + subpath, [path2]]];
|
|
5706
5708
|
}
|
|
5707
5709
|
}
|
|
5708
5710
|
const path = await resolveTypePath(_pkg + subpath, subpath, nuxt.options.modulesDir);
|
|
5709
5711
|
if (path) {
|
|
5710
|
-
return [[
|
|
5712
|
+
return [[pkg2, [path]]];
|
|
5711
5713
|
}
|
|
5712
5714
|
return [];
|
|
5713
5715
|
})).then((r) => r.flat()));
|
|
@@ -6553,14 +6555,14 @@ async function getVueHash(nuxt) {
|
|
|
6553
6555
|
const start = Date.now();
|
|
6554
6556
|
await writeCache(nuxt.options.buildDir, nuxt.options.buildDir, cacheFile);
|
|
6555
6557
|
const elapsed = Date.now() - start;
|
|
6556
|
-
consola
|
|
6558
|
+
consola.success(`Cached Vue client and server builds in \`${elapsed}ms\`.`);
|
|
6557
6559
|
},
|
|
6558
6560
|
async restoreCache() {
|
|
6559
6561
|
const start = Date.now();
|
|
6560
6562
|
const res = await restoreCache(nuxt.options.buildDir, cacheFile);
|
|
6561
6563
|
const elapsed = Date.now() - start;
|
|
6562
6564
|
if (res) {
|
|
6563
|
-
consola
|
|
6565
|
+
consola.success(`Restored Vue client and server builds from cache in \`${elapsed}ms\`.`);
|
|
6564
6566
|
}
|
|
6565
6567
|
return res;
|
|
6566
6568
|
}
|
|
@@ -6581,7 +6583,7 @@ async function cleanupCaches(nuxt) {
|
|
|
6581
6583
|
await unlink(cache);
|
|
6582
6584
|
}
|
|
6583
6585
|
const elapsed = Date.now() - start;
|
|
6584
|
-
consola
|
|
6586
|
+
consola.success(`Cleaned up old build caches in \`${elapsed}ms\`.`);
|
|
6585
6587
|
}
|
|
6586
6588
|
}
|
|
6587
6589
|
async function getHashes(nuxt, options) {
|
|
@@ -6646,7 +6648,7 @@ async function getHashes(nuxt, options) {
|
|
|
6646
6648
|
sources: hashSources
|
|
6647
6649
|
};
|
|
6648
6650
|
const elapsed = Date.now() - start;
|
|
6649
|
-
consola
|
|
6651
|
+
consola.debug(`Computed \`${options.id}\` build hash in \`${elapsed}ms\`.`);
|
|
6650
6652
|
return res;
|
|
6651
6653
|
}
|
|
6652
6654
|
async function readFilesRecursive(dir, opts) {
|
|
@@ -6714,7 +6716,7 @@ async function restoreCache(cwd, cacheFile) {
|
|
|
6714
6716
|
if (stats?.isFile() && stats.size) {
|
|
6715
6717
|
const lastModified = Number.parseInt(file.attrs?.mtime?.toString().padEnd(13, "0") || "0");
|
|
6716
6718
|
if (stats.mtime.getTime() >= lastModified) {
|
|
6717
|
-
consola
|
|
6719
|
+
consola.debug(`Skipping \`${file.name}\` (up to date or newer than cache)`);
|
|
6718
6720
|
continue;
|
|
6719
6721
|
}
|
|
6720
6722
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { joinURL } from "ufo";
|
|
2
2
|
import { createRouter as createRadixRouter, toRouteMatcher } from "radix3";
|
|
3
|
-
import defu from "defu";
|
|
3
|
+
import { defu } from "defu";
|
|
4
4
|
import { defineNuxtPlugin, useRuntimeConfig } from "#app/nuxt";
|
|
5
5
|
import { prerenderRoutes } from "#app/composables/ssr";
|
|
6
6
|
import _routes from "#build/routes";
|
|
7
|
-
import routerOptions, { hashMode } from "#build/router.options";
|
|
7
|
+
import routerOptions, { hashMode } from "#build/router.options.mjs";
|
|
8
8
|
import { crawlLinks } from "#build/nuxt.config.mjs";
|
|
9
9
|
let routes;
|
|
10
10
|
let _routeRulesMatcher = void 0;
|
|
@@ -8,7 +8,7 @@ import { clearError, createError, isNuxtError, showError, useError } from "#app/
|
|
|
8
8
|
import { navigateTo } from "#app/composables/router";
|
|
9
9
|
import { appManifest as isAppManifestEnabled } from "#build/nuxt.config.mjs";
|
|
10
10
|
import _routes, { handleHotUpdate } from "#build/routes";
|
|
11
|
-
import routerOptions, { hashMode } from "#build/router.options";
|
|
11
|
+
import routerOptions, { hashMode } from "#build/router.options.mjs";
|
|
12
12
|
import { globalMiddleware, namedMiddleware } from "#build/middleware";
|
|
13
13
|
function createCurrentLocation(base, location, renderedPath) {
|
|
14
14
|
const { pathname, search, hash } = location;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nuxt-nightly",
|
|
3
|
-
"version": "4.3.0-
|
|
3
|
+
"version": "4.3.0-29431381.f1713850",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/nuxt/nuxt.git",
|
|
@@ -67,11 +67,11 @@
|
|
|
67
67
|
"@dxup/nuxt": "^0.3.2",
|
|
68
68
|
"@nuxt/cli": "npm:@nuxt/cli-nightly@latest",
|
|
69
69
|
"@nuxt/devtools": "^3.1.1",
|
|
70
|
-
"@nuxt/kit": "npm:@nuxt/kit-nightly@4.3.0-
|
|
71
|
-
"@nuxt/nitro-server": "npm:@nuxt/nitro-server-nightly@4.3.0-
|
|
72
|
-
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.3.0-
|
|
70
|
+
"@nuxt/kit": "npm:@nuxt/kit-nightly@4.3.0-29431381.f1713850",
|
|
71
|
+
"@nuxt/nitro-server": "npm:@nuxt/nitro-server-nightly@4.3.0-29431381.f1713850",
|
|
72
|
+
"@nuxt/schema": "npm:@nuxt/schema-nightly@4.3.0-29431381.f1713850",
|
|
73
73
|
"@nuxt/telemetry": "^2.6.6",
|
|
74
|
-
"@nuxt/vite-builder": "npm:@nuxt/vite-builder-nightly@4.3.0-
|
|
74
|
+
"@nuxt/vite-builder": "npm:@nuxt/vite-builder-nightly@4.3.0-29431381.f1713850",
|
|
75
75
|
"@unhead/vue": "^2.0.19",
|
|
76
76
|
"@vue/shared": "^3.5.25",
|
|
77
77
|
"c12": "^3.3.2",
|