@voidzero-dev/vite-plus-core 0.1.13-alpha.3 → 0.1.13-alpha.5
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/esm-shims.js +9 -0
- package/dist/rolldown/cli.mjs +211 -73
- package/dist/rolldown/config.d.mts +1 -1
- package/dist/rolldown/config.mjs +8 -8
- package/dist/rolldown/experimental-index.d.mts +7 -7
- package/dist/rolldown/experimental-index.mjs +12 -13
- package/dist/rolldown/filter-index.d.mts +1 -1
- package/dist/rolldown/index.d.mts +3 -3
- package/dist/rolldown/index.mjs +9 -9
- package/dist/rolldown/parallel-plugin-worker.mjs +5 -5
- package/dist/rolldown/parallel-plugin.d.mts +1 -1
- package/dist/rolldown/parse-ast-index.d.mts +1 -1
- package/dist/rolldown/parse-ast-index.mjs +2 -2
- package/dist/rolldown/plugins-index.d.mts +3 -3
- package/dist/rolldown/plugins-index.mjs +3 -3
- package/dist/rolldown/shared/{binding-BohGL_65.d.mts → binding-Dsq9Azhm.d.mts} +14 -17
- package/dist/rolldown/shared/{bindingify-input-options-D6u7COm1.mjs → bindingify-input-options-nddSVL89.mjs} +16 -11
- package/dist/rolldown/shared/{constructors-DNuo4d0H.d.mts → constructors-DfpIbfMG.d.mts} +7 -3
- package/dist/rolldown/shared/{constructors-Ctal_Rbv.mjs → constructors-DqC7XSXy.mjs} +8 -2
- package/dist/rolldown/shared/{define-config-cG45vHwf.d.mts → define-config-CV9D_Qea.d.mts} +19 -12
- package/dist/rolldown/shared/{error-CP8smW_P.mjs → error-BO4SlZV_.mjs} +1 -1
- package/dist/rolldown/shared/{load-config-CjCoDD5h.mjs → load-config-CDqvxxnl.mjs} +1 -1
- package/dist/rolldown/shared/{normalize-string-or-regex-C5RWbu3O.mjs → normalize-string-or-regex-D7wlw16t.mjs} +1 -1
- package/dist/rolldown/shared/{parse-BhVn_3w_.mjs → parse-WOgXxW4-.mjs} +1 -1
- package/dist/rolldown/shared/{transform-BfdLLNnY.mjs → resolve-tsconfig-C3OzszY-.mjs} +28 -5
- package/dist/rolldown/shared/{rolldown-B7hI_r7G.mjs → rolldown-DUOYLKyH.mjs} +1 -1
- package/dist/rolldown/shared/{rolldown-build-CYoDea9V.mjs → rolldown-build-C7TjtSci.mjs} +4 -4
- package/dist/rolldown/shared/{transform-BoJxrM-e.d.mts → transform-B5D1aA1B.d.mts} +19 -2
- package/dist/rolldown/shared/{watch-CAj7leYN.mjs → watch-BV1BB_LU.mjs} +4 -4
- package/dist/rolldown/utils-index.d.mts +2 -2
- package/dist/rolldown/utils-index.mjs +4 -5
- package/dist/tsdown/{build-CoLhkNXE-DtR1EaBG.js → build-CoLhkNXE-DccPqXpK.js} +7 -7
- package/dist/tsdown/{build-dhDyu66J-DxSssGzc.js → build-dhDyu66J-C3xzaksU.js} +2 -2
- package/dist/tsdown/{debug-C4FmgzkJ-Co4tnxmE.js → debug-C4FmgzkJ-BxvFHEjv.js} +2 -2
- package/dist/tsdown/{detect-DN3DXXYt-BiiMP_XL.js → detect-DN3DXXYt-CgZGWZG7.js} +1 -1
- package/dist/tsdown/index-types.d.ts +6 -6
- package/dist/tsdown/index.js +4 -4
- package/dist/tsdown/{main-JovZVvCY.js → main-CU_sednE.js} +2 -2
- package/dist/tsdown/run.js +3 -3
- package/dist/vite/client/client.mjs +12 -12
- package/dist/vite/client/env.mjs +1 -1
- package/dist/vite/node/chunks/build2.js +5 -14
- package/dist/vite/node/chunks/dist.js +6 -11
- package/dist/vite/node/chunks/dist2.js +1 -4
- package/dist/vite/node/chunks/logger.js +4 -4
- package/dist/vite/node/chunks/node.js +193 -178
- package/dist/vite/node/cli.js +1 -1
- package/dist/vite/node/index.d.ts +3 -3
- package/dist/vite/node/module-runner.js +18 -18
- package/package.json +7 -7
- /package/dist/rolldown/shared/{binding-C5G6_6ql.mjs → binding-BV_UWDF3.mjs} +0 -0
|
@@ -20,7 +20,7 @@ import { promises } from "node:dns";
|
|
|
20
20
|
import { isatty } from "node:tty";
|
|
21
21
|
import path$1, { basename as basename$1, dirname as dirname$1, isAbsolute as isAbsolute$1, join as join$1, normalize as normalize$1, posix as posix$1, relative as relative$1, resolve as resolve$1, sep as sep$1, win32 } from "path";
|
|
22
22
|
import { exactRegex, makeIdFiltersToMatchWithQuery, prefixRegex, withFilter } from "@voidzero-dev/vite-plus-core/rolldown/filter";
|
|
23
|
-
import { dev, resolveTsconfig, scan, viteAliasPlugin, viteBuildImportAnalysisPlugin, viteDynamicImportVarsPlugin, viteImportGlobPlugin, viteJsonPlugin, viteLoadFallbackPlugin, viteManifestPlugin, viteModulePreloadPolyfillPlugin, viteReporterPlugin, viteResolvePlugin, viteTransformPlugin, viteWasmFallbackPlugin, viteWebWorkerPostPlugin } from "@voidzero-dev/vite-plus-core/rolldown/experimental";
|
|
23
|
+
import { dev, oxcRuntimePlugin, resolveTsconfig, scan, viteAliasPlugin, viteBuildImportAnalysisPlugin, viteDynamicImportVarsPlugin, viteImportGlobPlugin, viteJsonPlugin, viteLoadFallbackPlugin, viteManifestPlugin, viteModulePreloadPolyfillPlugin, viteReporterPlugin, viteResolvePlugin, viteTransformPlugin, viteWasmFallbackPlugin, viteWebWorkerPostPlugin } from "@voidzero-dev/vite-plus-core/rolldown/experimental";
|
|
24
24
|
import readline from "node:readline";
|
|
25
25
|
import { MessageChannel, Worker } from "node:worker_threads";
|
|
26
26
|
import isModuleSyncConditionEnabled from "#module-sync-enabled";
|
|
@@ -1436,15 +1436,12 @@ var require_picomatch$3 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1436
1436
|
const state = regex.state;
|
|
1437
1437
|
delete regex.state;
|
|
1438
1438
|
let isIgnored = () => false;
|
|
1439
|
-
if (opts.ignore) {
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
};
|
|
1446
|
-
isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);
|
|
1447
|
-
}
|
|
1439
|
+
if (opts.ignore) isIgnored = picomatch(opts.ignore, {
|
|
1440
|
+
...options,
|
|
1441
|
+
ignore: null,
|
|
1442
|
+
onMatch: null,
|
|
1443
|
+
onResult: null
|
|
1444
|
+
}, returnState);
|
|
1448
1445
|
const matcher = (input, returnObject = false) => {
|
|
1449
1446
|
const { isMatch, match, output } = picomatch.test(input, regex, options, {
|
|
1450
1447
|
glob,
|
|
@@ -1693,7 +1690,7 @@ var require_picomatch$2 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1693
1690
|
module.exports = picomatch;
|
|
1694
1691
|
}));
|
|
1695
1692
|
//#endregion
|
|
1696
|
-
//#region ../../
|
|
1693
|
+
//#region ../../vite/packages/vite/src/shared/constants.ts
|
|
1697
1694
|
/**
|
|
1698
1695
|
* Prefix for resolved Ids that are not valid browser import specifiers
|
|
1699
1696
|
*/
|
|
@@ -1715,7 +1712,7 @@ SOURCEMAPPING_URL += "ppingURL";
|
|
|
1715
1712
|
const MODULE_RUNNER_SOURCEMAPPING_SOURCE = "//# sourceMappingSource=vite-generated";
|
|
1716
1713
|
const ERR_OUTDATED_OPTIMIZED_DEP = "ERR_OUTDATED_OPTIMIZED_DEP";
|
|
1717
1714
|
//#endregion
|
|
1718
|
-
//#region ../../
|
|
1715
|
+
//#region ../../vite/packages/vite/src/shared/utils.ts
|
|
1719
1716
|
const isWindows = typeof process !== "undefined" && process.platform === "win32";
|
|
1720
1717
|
/**
|
|
1721
1718
|
* Prepend `/@id/` and replace null byte so the id is URL-safe.
|
|
@@ -1763,7 +1760,7 @@ function promiseWithResolvers() {
|
|
|
1763
1760
|
};
|
|
1764
1761
|
}
|
|
1765
1762
|
//#endregion
|
|
1766
|
-
//#region ../../
|
|
1763
|
+
//#region ../../vite/packages/vite/src/module-runner/importMetaResolver.ts
|
|
1767
1764
|
const customizationHookNamespace = "vite-module-runner:import-meta-resolve/v1/";
|
|
1768
1765
|
const customizationHooksModule = `
|
|
1769
1766
|
|
|
@@ -2634,8 +2631,7 @@ function setup(useColors, colors, log, load, save, formatArgs, init) {
|
|
|
2634
2631
|
index++;
|
|
2635
2632
|
const formatter = createDebug.formatters[format];
|
|
2636
2633
|
if (typeof formatter === "function") {
|
|
2637
|
-
|
|
2638
|
-
match = formatter.call(debug, value);
|
|
2634
|
+
match = formatter.call(debug, args[index]);
|
|
2639
2635
|
args.splice(index, 1);
|
|
2640
2636
|
index--;
|
|
2641
2637
|
}
|
|
@@ -2989,14 +2985,14 @@ const dataToEsm = function dataToEsm(data, options = {}) {
|
|
|
2989
2985
|
return `${namedExportCode}${arbitraryExportCode}${defaultExportCode}`;
|
|
2990
2986
|
};
|
|
2991
2987
|
//#endregion
|
|
2992
|
-
//#region ../../
|
|
2988
|
+
//#region ../../vite/packages/vite/src/shared/builtin.ts
|
|
2993
2989
|
function createIsBuiltin(builtins) {
|
|
2994
2990
|
const plainBuiltinsSet = new Set(builtins.filter((builtin) => typeof builtin === "string"));
|
|
2995
2991
|
const regexBuiltins = builtins.filter((builtin) => typeof builtin !== "string");
|
|
2996
2992
|
return (id) => plainBuiltinsSet.has(id) || regexBuiltins.some((regexp) => regexp.test(id));
|
|
2997
2993
|
}
|
|
2998
2994
|
//#endregion
|
|
2999
|
-
//#region ../../
|
|
2995
|
+
//#region ../../vite/packages/vite/src/node/packages.ts
|
|
3000
2996
|
let pnp;
|
|
3001
2997
|
if (process.versions.pnp) try {
|
|
3002
2998
|
pnp = createRequire(
|
|
@@ -3205,15 +3201,16 @@ function traverseBetweenDirs(longerDir, shorterDir, cb) {
|
|
|
3205
3201
|
}
|
|
3206
3202
|
}
|
|
3207
3203
|
//#endregion
|
|
3208
|
-
//#region ../../
|
|
3204
|
+
//#region ../../vite/packages/vite/src/node/utils.ts
|
|
3209
3205
|
var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
|
|
3210
3206
|
const createFilter$1 = createFilter$2;
|
|
3211
3207
|
const replaceSlashOrColonRE = /[/:]/g;
|
|
3212
3208
|
const replaceDotRE = /\./g;
|
|
3213
3209
|
const replaceNestedIdRE = /\s*>\s*/g;
|
|
3214
3210
|
const replaceHashRE = /#/g;
|
|
3211
|
+
const replacePlusRE = /\+/g;
|
|
3215
3212
|
const flattenId = (id) => {
|
|
3216
|
-
return limitFlattenIdLength(id.replace(replaceSlashOrColonRE, "_").replace(replaceDotRE, "__").replace(replaceNestedIdRE, "___").replace(replaceHashRE, "____"));
|
|
3213
|
+
return limitFlattenIdLength(id.replace(replaceSlashOrColonRE, "_").replace(replaceDotRE, "__").replace(replaceNestedIdRE, "___").replace(replaceHashRE, "____").replace(replacePlusRE, "_____"));
|
|
3217
3214
|
};
|
|
3218
3215
|
const FLATTEN_ID_HASH_LENGTH = 8;
|
|
3219
3216
|
const FLATTEN_ID_MAX_FILE_LENGTH = 170;
|
|
@@ -3333,13 +3330,12 @@ const isJSRequest = (url) => {
|
|
|
3333
3330
|
const isCSSRequest = (request) => CSS_LANGS_RE.test(request);
|
|
3334
3331
|
const importQueryRE = /(\?|&)import=?(?:&|$)/;
|
|
3335
3332
|
const directRequestRE$1 = /(\?|&)direct=?(?:&|$)/;
|
|
3336
|
-
const
|
|
3333
|
+
const InternalPrefixRE = new RegExp(`^(?:${[
|
|
3337
3334
|
FS_PREFIX,
|
|
3338
3335
|
VALID_ID_PREFIX,
|
|
3339
3336
|
CLIENT_PUBLIC_PATH,
|
|
3340
3337
|
ENV_PUBLIC_PATH
|
|
3341
|
-
];
|
|
3342
|
-
const InternalPrefixRE = new RegExp(`^(?:${internalPrefixes.join("|")})`);
|
|
3338
|
+
].join("|")})`);
|
|
3343
3339
|
const trailingSeparatorRE = /[?&]$/;
|
|
3344
3340
|
const isImportRequest = (url) => importQueryRE.test(url);
|
|
3345
3341
|
const isInternalRequest = (url) => InternalPrefixRE.test(url);
|
|
@@ -4167,7 +4163,7 @@ function monotonicDateNow() {
|
|
|
4167
4163
|
return lastDateNow;
|
|
4168
4164
|
}
|
|
4169
4165
|
//#endregion
|
|
4170
|
-
//#region ../../
|
|
4166
|
+
//#region ../../vite/packages/vite/src/node/plugin.ts
|
|
4171
4167
|
async function resolveEnvironmentPlugins(environment) {
|
|
4172
4168
|
const environmentPlugins = [];
|
|
4173
4169
|
for (const plugin of environment.getTopLevelConfig().plugins) {
|
|
@@ -4193,7 +4189,7 @@ function perEnvironmentPlugin(name, applyToEnvironment) {
|
|
|
4193
4189
|
};
|
|
4194
4190
|
}
|
|
4195
4191
|
//#endregion
|
|
4196
|
-
//#region ../../
|
|
4192
|
+
//#region ../../vite/packages/vite/src/node/plugins/reporter.ts
|
|
4197
4193
|
const VITE_VERSION_ONLY_LINE_RE = /^vite v\S+$/;
|
|
4198
4194
|
function buildReporterPlugin(config) {
|
|
4199
4195
|
return perEnvironmentPlugin("native:reporter", (env) => {
|
|
@@ -4216,7 +4212,7 @@ function buildReporterPlugin(config) {
|
|
|
4216
4212
|
});
|
|
4217
4213
|
}
|
|
4218
4214
|
//#endregion
|
|
4219
|
-
//#region ../../
|
|
4215
|
+
//#region ../../vite/packages/vite/src/node/plugins/esbuild.ts
|
|
4220
4216
|
const debug$14 = createDebugger("vite:esbuild");
|
|
4221
4217
|
const IIFE_BEGIN_RE$1 = /(?:const|var)\s+\S+\s*=\s*\(?function\([^()]*\)\s*\{\s*"use strict";/;
|
|
4222
4218
|
const validExtensionRE$1 = /\.\w+$/;
|
|
@@ -4855,6 +4851,7 @@ function encodeQueryItem(key, value) {
|
|
|
4855
4851
|
function stringifyQuery(query) {
|
|
4856
4852
|
return Object.keys(query).filter((k) => query[k] !== void 0).map((k) => encodeQueryItem(k, query[k])).filter(Boolean).join("&");
|
|
4857
4853
|
}
|
|
4854
|
+
new Set(builtinModules);
|
|
4858
4855
|
function clearImports(imports) {
|
|
4859
4856
|
return (imports || "").replace(/\/\/[^\n]*\n|\/\*.*\*\//g, "").replace(/\s+/g, " ");
|
|
4860
4857
|
}
|
|
@@ -5196,7 +5193,8 @@ function determineSpecificType(value) {
|
|
|
5196
5193
|
if (inspected.length > 28) inspected = `${inspected.slice(0, 25)}...`;
|
|
5197
5194
|
return `type ${typeof value} (${inspected})`;
|
|
5198
5195
|
}
|
|
5199
|
-
Object.freeze(["node", "import"]);
|
|
5196
|
+
const DEFAULT_CONDITIONS = Object.freeze(["node", "import"]);
|
|
5197
|
+
new Set(DEFAULT_CONDITIONS);
|
|
5200
5198
|
const ESM_STATIC_IMPORT_RE = /(?<=\s|^|;|\})import\s*(?:[\s"']*(?<imports>[\p{L}\p{M}\w\t\n\r $*,/{}@.]+)from\s*)?["']\s*(?<specifier>(?<="\s*)[^"]*[^\s"](?=\s*")|(?<='\s*)[^']*[^\s'](?=\s*'))\s*["'][\s;]*/gmu;
|
|
5201
5199
|
const TYPE_RE = /^\s*?type\s/;
|
|
5202
5200
|
function parseStaticImport(matched) {
|
|
@@ -6092,7 +6090,7 @@ function globSync(patternsOrOptions, options) {
|
|
|
6092
6090
|
return formatPaths(crawler.sync(), relative);
|
|
6093
6091
|
}
|
|
6094
6092
|
//#endregion
|
|
6095
|
-
//#region ../../
|
|
6093
|
+
//#region ../../vite/packages/vite/src/node/plugins/oxc.ts
|
|
6096
6094
|
const IIFE_BEGIN_RE = /(?:(?:(?:const|var)\s+[^.\s]+|[^.\s]+\.[^.\s]+\.[^.\s]+)\s*=\s*|^|\n)\(?function\([^()]*\)\s*\{(?:\s*"use strict";)?/;
|
|
6097
6095
|
const UMD_BEGIN_RE = /\}\)\((?:this,\s*)?function\([^()]*\)\s*\{(?:\s*"use strict";)?/;
|
|
6098
6096
|
const jsxExtensionsRE = /\.(?:j|t)sx\b/;
|
|
@@ -6220,20 +6218,12 @@ function oxcPlugin(config) {
|
|
|
6220
6218
|
if (jsxRefreshFilter?.(id) && !JS_TYPES_RE.test(cleanUrl(id))) result.lang = "js";
|
|
6221
6219
|
return result;
|
|
6222
6220
|
};
|
|
6223
|
-
const runtimeResolveBase = normalizePath$1(path.join(VITE_PACKAGE_DIR, "package.json"));
|
|
6224
6221
|
let server;
|
|
6225
6222
|
return {
|
|
6226
6223
|
name: "vite:oxc",
|
|
6227
6224
|
configureServer(_server) {
|
|
6228
6225
|
server = _server;
|
|
6229
6226
|
},
|
|
6230
|
-
...config.command === "serve" ? { resolveId: {
|
|
6231
|
-
filter: { id: prefixRegex("@oxc-project/runtime/") },
|
|
6232
|
-
async handler(id, _importer, opts) {
|
|
6233
|
-
return await this.resolve(id, runtimeResolveBase, opts);
|
|
6234
|
-
},
|
|
6235
|
-
order: "pre"
|
|
6236
|
-
} } : {},
|
|
6237
6227
|
async transform(code, id) {
|
|
6238
6228
|
if (filter(id) || filter(cleanUrl(id)) || jsxRefreshFilter?.(id)) {
|
|
6239
6229
|
const result = await transformWithOxc(code, id, getModifiedOxcTransformOptions(oxcTransformOptions, id, code, this.environment), void 0, config, server?.watcher);
|
|
@@ -7278,7 +7268,7 @@ function alias$1(options = {}) {
|
|
|
7278
7268
|
};
|
|
7279
7269
|
}
|
|
7280
7270
|
//#endregion
|
|
7281
|
-
//#region ../../
|
|
7271
|
+
//#region ../../vite/packages/vite/src/node/plugins/optimizedDeps.ts
|
|
7282
7272
|
const debug$13 = createDebugger("vite:optimize-deps");
|
|
7283
7273
|
function optimizedDepsPlugin() {
|
|
7284
7274
|
return {
|
|
@@ -7338,7 +7328,7 @@ function throwFileNotFoundInOptimizedDep(id) {
|
|
|
7338
7328
|
throw err;
|
|
7339
7329
|
}
|
|
7340
7330
|
//#endregion
|
|
7341
|
-
//#region ../../
|
|
7331
|
+
//#region ../../vite/packages/vite/src/node/env.ts
|
|
7342
7332
|
var import_main = (/* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
7343
7333
|
function _resolveEscapeSequences(value) {
|
|
7344
7334
|
return value.replace(/\\\$/g, "$");
|
|
@@ -7435,7 +7425,7 @@ function resolveEnvPrefix({ envPrefix = "VITE_" }) {
|
|
|
7435
7425
|
return envPrefix;
|
|
7436
7426
|
}
|
|
7437
7427
|
//#endregion
|
|
7438
|
-
//#region ../../
|
|
7428
|
+
//#region ../../vite/packages/vite/src/node/deprecations.ts
|
|
7439
7429
|
const docsURL = "https://vite.dev";
|
|
7440
7430
|
const deprecationCode = {
|
|
7441
7431
|
removePluginHookSsrArgument: "this-environment-in-hooks",
|
|
@@ -7492,7 +7482,7 @@ function ignoreDeprecationWarnings(fn) {
|
|
|
7492
7482
|
return ret;
|
|
7493
7483
|
}
|
|
7494
7484
|
//#endregion
|
|
7495
|
-
//#region ../../
|
|
7485
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/error.ts
|
|
7496
7486
|
function prepareError(err) {
|
|
7497
7487
|
return {
|
|
7498
7488
|
message: stripVTControlCharacters(err.message),
|
|
@@ -7743,8 +7733,7 @@ var require_debug$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
7743
7733
|
index++;
|
|
7744
7734
|
var formatter = exports.formatters[format];
|
|
7745
7735
|
if ("function" === typeof formatter) {
|
|
7746
|
-
|
|
7747
|
-
match = formatter.call(self, val);
|
|
7736
|
+
match = formatter.call(self, args[index]);
|
|
7748
7737
|
args.splice(index, 1);
|
|
7749
7738
|
index--;
|
|
7750
7739
|
}
|
|
@@ -10900,15 +10889,12 @@ var require_picomatch$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
10900
10889
|
const state = regex.state;
|
|
10901
10890
|
delete regex.state;
|
|
10902
10891
|
let isIgnored = () => false;
|
|
10903
|
-
if (opts.ignore) {
|
|
10904
|
-
|
|
10905
|
-
|
|
10906
|
-
|
|
10907
|
-
|
|
10908
|
-
|
|
10909
|
-
};
|
|
10910
|
-
isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);
|
|
10911
|
-
}
|
|
10892
|
+
if (opts.ignore) isIgnored = picomatch(opts.ignore, {
|
|
10893
|
+
...options,
|
|
10894
|
+
ignore: null,
|
|
10895
|
+
onMatch: null,
|
|
10896
|
+
onResult: null
|
|
10897
|
+
}, returnState);
|
|
10912
10898
|
const matcher = (input, returnObject = false) => {
|
|
10913
10899
|
const { isMatch, match, output } = picomatch.test(input, regex, options, {
|
|
10914
10900
|
glob,
|
|
@@ -15067,7 +15053,7 @@ var require_launch_editor_middleware = /* @__PURE__ */ __commonJSMin(((exports,
|
|
|
15067
15053
|
};
|
|
15068
15054
|
}));
|
|
15069
15055
|
//#endregion
|
|
15070
|
-
//#region ../../node_modules/.pnpm/@vercel+detect-agent@1.1
|
|
15056
|
+
//#region ../../node_modules/.pnpm/@vercel+detect-agent@1.2.1/node_modules/@vercel/detect-agent/dist/index.js
|
|
15071
15057
|
var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
15072
15058
|
var __defProp = Object.defineProperty;
|
|
15073
15059
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
@@ -15101,30 +15087,43 @@ var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
15101
15087
|
const CURSOR = "cursor";
|
|
15102
15088
|
const CURSOR_CLI = "cursor-cli";
|
|
15103
15089
|
const CLAUDE = "claude";
|
|
15090
|
+
const COWORK = "cowork";
|
|
15104
15091
|
const DEVIN = "devin";
|
|
15105
15092
|
const REPLIT = "replit";
|
|
15106
15093
|
const GEMINI = "gemini";
|
|
15107
15094
|
const CODEX = "codex";
|
|
15095
|
+
const ANTIGRAVITY = "antigravity";
|
|
15108
15096
|
const AUGMENT_CLI = "augment-cli";
|
|
15109
15097
|
const OPENCODE = "opencode";
|
|
15098
|
+
const GITHUB_COPILOT = "github-copilot";
|
|
15099
|
+
const GITHUB_COPILOT_CLI = "github-copilot-cli";
|
|
15110
15100
|
const KNOWN_AGENTS = {
|
|
15111
15101
|
CURSOR,
|
|
15112
15102
|
CURSOR_CLI,
|
|
15113
15103
|
CLAUDE,
|
|
15104
|
+
COWORK,
|
|
15114
15105
|
DEVIN,
|
|
15115
15106
|
REPLIT,
|
|
15116
15107
|
GEMINI,
|
|
15117
15108
|
CODEX,
|
|
15109
|
+
ANTIGRAVITY,
|
|
15118
15110
|
AUGMENT_CLI,
|
|
15119
|
-
OPENCODE
|
|
15111
|
+
OPENCODE,
|
|
15112
|
+
GITHUB_COPILOT
|
|
15120
15113
|
};
|
|
15121
15114
|
async function determineAgent() {
|
|
15122
15115
|
if (process.env.AI_AGENT) {
|
|
15123
15116
|
const name = process.env.AI_AGENT.trim();
|
|
15124
|
-
if (name)
|
|
15125
|
-
|
|
15126
|
-
|
|
15127
|
-
|
|
15117
|
+
if (name) {
|
|
15118
|
+
if (name === GITHUB_COPILOT || name === GITHUB_COPILOT_CLI) return {
|
|
15119
|
+
isAgent: true,
|
|
15120
|
+
agent: { name: GITHUB_COPILOT }
|
|
15121
|
+
};
|
|
15122
|
+
return {
|
|
15123
|
+
isAgent: true,
|
|
15124
|
+
agent: { name }
|
|
15125
|
+
};
|
|
15126
|
+
}
|
|
15128
15127
|
}
|
|
15129
15128
|
if (process.env.CURSOR_TRACE_ID) return {
|
|
15130
15129
|
isAgent: true,
|
|
@@ -15138,10 +15137,14 @@ var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
15138
15137
|
isAgent: true,
|
|
15139
15138
|
agent: { name: GEMINI }
|
|
15140
15139
|
};
|
|
15141
|
-
if (process.env.CODEX_SANDBOX) return {
|
|
15140
|
+
if (process.env.CODEX_SANDBOX || process.env.CODEX_CI || process.env.CODEX_THREAD_ID) return {
|
|
15142
15141
|
isAgent: true,
|
|
15143
15142
|
agent: { name: CODEX }
|
|
15144
15143
|
};
|
|
15144
|
+
if (process.env.ANTIGRAVITY_AGENT) return {
|
|
15145
|
+
isAgent: true,
|
|
15146
|
+
agent: { name: ANTIGRAVITY }
|
|
15147
|
+
};
|
|
15145
15148
|
if (process.env.AUGMENT_AGENT) return {
|
|
15146
15149
|
isAgent: true,
|
|
15147
15150
|
agent: { name: AUGMENT_CLI }
|
|
@@ -15150,21 +15153,31 @@ var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
15150
15153
|
isAgent: true,
|
|
15151
15154
|
agent: { name: OPENCODE }
|
|
15152
15155
|
};
|
|
15153
|
-
if (process.env.CLAUDECODE || process.env.CLAUDE_CODE)
|
|
15154
|
-
|
|
15155
|
-
|
|
15156
|
-
|
|
15156
|
+
if (process.env.CLAUDECODE || process.env.CLAUDE_CODE) {
|
|
15157
|
+
if (process.env.CLAUDE_CODE_IS_COWORK) return {
|
|
15158
|
+
isAgent: true,
|
|
15159
|
+
agent: { name: COWORK }
|
|
15160
|
+
};
|
|
15161
|
+
return {
|
|
15162
|
+
isAgent: true,
|
|
15163
|
+
agent: { name: CLAUDE }
|
|
15164
|
+
};
|
|
15165
|
+
}
|
|
15157
15166
|
if (process.env.REPL_ID) return {
|
|
15158
15167
|
isAgent: true,
|
|
15159
15168
|
agent: { name: REPLIT }
|
|
15160
15169
|
};
|
|
15170
|
+
if (process.env.COPILOT_MODEL || process.env.COPILOT_ALLOW_ALL || process.env.COPILOT_GITHUB_TOKEN) return {
|
|
15171
|
+
isAgent: true,
|
|
15172
|
+
agent: { name: GITHUB_COPILOT }
|
|
15173
|
+
};
|
|
15161
15174
|
try {
|
|
15162
15175
|
await (0, import_promises.access)(DEVIN_LOCAL_PATH, import_node_fs.constants.F_OK);
|
|
15163
15176
|
return {
|
|
15164
15177
|
isAgent: true,
|
|
15165
15178
|
agent: { name: DEVIN }
|
|
15166
15179
|
};
|
|
15167
|
-
} catch (
|
|
15180
|
+
} catch (_error) {}
|
|
15168
15181
|
return {
|
|
15169
15182
|
isAgent: false,
|
|
15170
15183
|
agent: void 0
|
|
@@ -15172,7 +15185,7 @@ var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
15172
15185
|
}
|
|
15173
15186
|
}));
|
|
15174
15187
|
//#endregion
|
|
15175
|
-
//#region ../../
|
|
15188
|
+
//#region ../../vite/packages/vite/src/node/http.ts
|
|
15176
15189
|
async function resolveHttpServer(app, httpsOptions) {
|
|
15177
15190
|
if (!httpsOptions) {
|
|
15178
15191
|
const { createServer } = await import("node:http");
|
|
@@ -15269,7 +15282,7 @@ function setClientErrorHandler(server, logger) {
|
|
|
15269
15282
|
});
|
|
15270
15283
|
}
|
|
15271
15284
|
//#endregion
|
|
15272
|
-
//#region ../../
|
|
15285
|
+
//#region ../../vite/packages/vite/src/node/ssr/ssrStacktrace.ts
|
|
15273
15286
|
let offset;
|
|
15274
15287
|
function calculateOffsetOnce() {
|
|
15275
15288
|
if (offset !== void 0) return;
|
|
@@ -15330,7 +15343,7 @@ function ssrFixStacktrace(e, moduleGraph) {
|
|
|
15330
15343
|
rewroteStacktraces.add(e);
|
|
15331
15344
|
}
|
|
15332
15345
|
//#endregion
|
|
15333
|
-
//#region ../../
|
|
15346
|
+
//#region ../../vite/packages/vite/src/node/ssr/runtime/serverModuleRunner.ts
|
|
15334
15347
|
function createHMROptions(environment, options) {
|
|
15335
15348
|
if (environment.config.server.hmr === false || options.hmr === false) return false;
|
|
15336
15349
|
if (!("api" in environment.hot)) return false;
|
|
@@ -15389,7 +15402,7 @@ function createServerModuleRunner(environment, options = {}) {
|
|
|
15389
15402
|
}, options.evaluator);
|
|
15390
15403
|
}
|
|
15391
15404
|
//#endregion
|
|
15392
|
-
//#region ../../
|
|
15405
|
+
//#region ../../vite/packages/vite/src/node/ssr/ssrModuleLoader.ts
|
|
15393
15406
|
async function ssrLoadModule(url, server, fixStacktrace) {
|
|
15394
15407
|
const environment = server.environments.ssr;
|
|
15395
15408
|
if (!isRunnableDevEnvironment(environment)) throw new Error(`ssrLoadModule requires the 'ssr' environment to be a runnable environment.`);
|
|
@@ -15661,11 +15674,11 @@ function walk$1(ast, { enter, leave }) {
|
|
|
15661
15674
|
return new SyncWalker(enter, leave).visit(ast, null);
|
|
15662
15675
|
}
|
|
15663
15676
|
//#endregion
|
|
15664
|
-
//#region ../../
|
|
15677
|
+
//#region ../../vite/packages/vite/src/node/plugins/json.ts
|
|
15665
15678
|
const jsonLangRE = new RegExp(`\\.(?:json|json5)(?:$|\\?)`);
|
|
15666
15679
|
const isJSONRequest = (request) => jsonLangRE.test(request);
|
|
15667
15680
|
//#endregion
|
|
15668
|
-
//#region ../../
|
|
15681
|
+
//#region ../../vite/packages/vite/src/node/ssr/ssrTransform.ts
|
|
15669
15682
|
const ssrModuleExportsKey = `__vite_ssr_exports__`;
|
|
15670
15683
|
const ssrImportKey = `__vite_ssr_import__`;
|
|
15671
15684
|
const ssrDynamicImportKey = `__vite_ssr_dynamic_import__`;
|
|
@@ -16792,7 +16805,7 @@ var require_enoent = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
16792
16805
|
};
|
|
16793
16806
|
}));
|
|
16794
16807
|
//#endregion
|
|
16795
|
-
//#region ../../
|
|
16808
|
+
//#region ../../vite/packages/vite/src/node/server/openBrowser.ts
|
|
16796
16809
|
/**
|
|
16797
16810
|
* The following is modified based on source found in
|
|
16798
16811
|
* https://github.com/facebook/create-react-app
|
|
@@ -16889,7 +16902,7 @@ function execAsync(command, options) {
|
|
|
16889
16902
|
});
|
|
16890
16903
|
}
|
|
16891
16904
|
//#endregion
|
|
16892
|
-
//#region ../../
|
|
16905
|
+
//#region ../../vite/packages/vite/src/node/shortcuts.ts
|
|
16893
16906
|
function bindCLIShortcuts(server, opts, enabled = process.stdin.isTTY && !process.env.CI) {
|
|
16894
16907
|
if (!server.httpServer || !enabled) return;
|
|
16895
16908
|
const isDev = isDevServer(server);
|
|
@@ -17000,7 +17013,7 @@ const BASE_PREVIEW_SHORTCUTS = [{
|
|
|
17000
17013
|
}
|
|
17001
17014
|
}];
|
|
17002
17015
|
//#endregion
|
|
17003
|
-
//#region ../../
|
|
17016
|
+
//#region ../../vite/packages/vite/src/node/watch.ts
|
|
17004
17017
|
function getResolvedOutDirs(root, outDir, outputOptions) {
|
|
17005
17018
|
const resolvedOutDir = path.resolve(root, outDir);
|
|
17006
17019
|
if (!outputOptions) return new Set([resolvedOutDir]);
|
|
@@ -17064,7 +17077,7 @@ function createNoopWatcher(options) {
|
|
|
17064
17077
|
return new NoopWatcher(options);
|
|
17065
17078
|
}
|
|
17066
17079
|
//#endregion
|
|
17067
|
-
//#region ../../
|
|
17080
|
+
//#region ../../vite/packages/vite/src/node/publicDir.ts
|
|
17068
17081
|
const publicFilesMap = /* @__PURE__ */ new WeakMap();
|
|
17069
17082
|
async function initPublicFiles(config) {
|
|
17070
17083
|
let fileNames;
|
|
@@ -20672,7 +20685,7 @@ function generateDefaultErrorMessage(hostname) {
|
|
|
20672
20685
|
return `Blocked request. This host (${JSON.stringify(hostname)}) is not allowed.`;
|
|
20673
20686
|
}
|
|
20674
20687
|
//#endregion
|
|
20675
|
-
//#region ../../
|
|
20688
|
+
//#region ../../vite/packages/vite/src/node/server/ws.ts
|
|
20676
20689
|
const WebSocketServerRaw = process.versions.bun ? import.meta.require("ws").WebSocketServer : import_websocket_server.default;
|
|
20677
20690
|
const isWebSocketServer = Symbol("isWebSocketServer");
|
|
20678
20691
|
const wsServerEvents = [
|
|
@@ -20891,7 +20904,7 @@ function createWebSocketServer(server, config, httpsOptions) {
|
|
|
20891
20904
|
};
|
|
20892
20905
|
}
|
|
20893
20906
|
//#endregion
|
|
20894
|
-
//#region ../../
|
|
20907
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/base.ts
|
|
20895
20908
|
function baseMiddleware(rawBase, middlewareMode) {
|
|
20896
20909
|
return function viteBaseMiddleware(req, res, next) {
|
|
20897
20910
|
const url = req.url;
|
|
@@ -21110,8 +21123,7 @@ var require_common$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
21110
21123
|
index++;
|
|
21111
21124
|
const formatter = createDebug.formatters[format];
|
|
21112
21125
|
if (typeof formatter === "function") {
|
|
21113
|
-
|
|
21114
|
-
match = formatter.call(self, val);
|
|
21126
|
+
match = formatter.call(self, args[index]);
|
|
21115
21127
|
args.splice(index, 1);
|
|
21116
21128
|
index--;
|
|
21117
21129
|
}
|
|
@@ -23031,7 +23043,7 @@ var require_http_proxy = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
23031
23043
|
};
|
|
23032
23044
|
}));
|
|
23033
23045
|
//#endregion
|
|
23034
|
-
//#region ../../
|
|
23046
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/proxy.ts
|
|
23035
23047
|
var import_lib$1 = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
23036
23048
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23037
23049
|
exports.numOpenSockets = exports.ProxyServer = void 0;
|
|
@@ -23260,7 +23272,7 @@ var require_etag = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
23260
23272
|
}
|
|
23261
23273
|
}));
|
|
23262
23274
|
//#endregion
|
|
23263
|
-
//#region ../../
|
|
23275
|
+
//#region ../../vite/packages/vite/src/node/environment.ts
|
|
23264
23276
|
/**
|
|
23265
23277
|
* Creates a function that hides the complexities of a WeakMap with an initial value
|
|
23266
23278
|
* to implement object metadata. Used by plugins to implement cross hooks per
|
|
@@ -23702,7 +23714,7 @@ function stripLiteral(code, options) {
|
|
|
23702
23714
|
return result;
|
|
23703
23715
|
}
|
|
23704
23716
|
//#endregion
|
|
23705
|
-
//#region ../../
|
|
23717
|
+
//#region ../../vite/packages/vite/src/node/assetSource.ts
|
|
23706
23718
|
const ALLOWED_META_NAME = [
|
|
23707
23719
|
"msapplication-tileimage",
|
|
23708
23720
|
"msapplication-square70x70logo",
|
|
@@ -23775,13 +23787,12 @@ function getNodeAssetAttributes(node) {
|
|
|
23775
23787
|
value,
|
|
23776
23788
|
attributes
|
|
23777
23789
|
})) return;
|
|
23778
|
-
const location = node.sourceCodeLocation.attrs[key];
|
|
23779
23790
|
actions.push({
|
|
23780
23791
|
type,
|
|
23781
23792
|
key,
|
|
23782
23793
|
value,
|
|
23783
23794
|
attributes,
|
|
23784
|
-
location
|
|
23795
|
+
location: node.sourceCodeLocation.attrs[key]
|
|
23785
23796
|
});
|
|
23786
23797
|
}
|
|
23787
23798
|
matched.srcAttributes?.forEach((key) => handleAttributeKey(key, "src"));
|
|
@@ -24239,7 +24250,7 @@ function lookup(extn) {
|
|
|
24239
24250
|
return mimes[!~idx ? tmp : tmp.substring(++idx)];
|
|
24240
24251
|
}
|
|
24241
24252
|
//#endregion
|
|
24242
|
-
//#region ../../
|
|
24253
|
+
//#region ../../vite/packages/vite/src/node/plugins/asset.ts
|
|
24243
24254
|
const assetUrlRE = /__VITE_ASSET__([\w$]+)__(?:\$_(.*?)__)?/g;
|
|
24244
24255
|
const jsSourceMapRE = /\.[cm]?js\.map$/;
|
|
24245
24256
|
const noInlineRE = /[?&]no-inline\b/;
|
|
@@ -25102,7 +25113,7 @@ var require_src = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
25102
25113
|
module.exports = rc;
|
|
25103
25114
|
}));
|
|
25104
25115
|
//#endregion
|
|
25105
|
-
//#region ../../
|
|
25116
|
+
//#region ../../vite/packages/vite/src/node/server/sourcemap.ts
|
|
25106
25117
|
var import_convert_source_map = /* @__PURE__ */ __toESM((/* @__PURE__ */ __commonJSMin(((exports) => {
|
|
25107
25118
|
Object.defineProperty(exports, "commentRegex", { get: function getCommentRegex() {
|
|
25108
25119
|
return /^\s*?\/[\/\*][@#]\s+?sourceMappingURL=data:(((?:application|text)\/json)(?:;charset=([^;,]+?)?)?)?(?:;(base64))?,(.*?)$/gm;
|
|
@@ -25322,7 +25333,7 @@ function createConvertSourceMapReadMap(originalFileName) {
|
|
|
25322
25333
|
};
|
|
25323
25334
|
}
|
|
25324
25335
|
//#endregion
|
|
25325
|
-
//#region ../../
|
|
25336
|
+
//#region ../../vite/packages/vite/src/node/idResolver.ts
|
|
25326
25337
|
/**
|
|
25327
25338
|
* Some projects like Astro were overriding config.createResolver to add a custom
|
|
25328
25339
|
* alias plugin. For the client and ssr environments, we root through it to avoid
|
|
@@ -25375,7 +25386,7 @@ function createIdResolver(config, options) {
|
|
|
25375
25386
|
};
|
|
25376
25387
|
}
|
|
25377
25388
|
//#endregion
|
|
25378
|
-
//#region ../../
|
|
25389
|
+
//#region ../../vite/packages/vite/src/node/baseEnvironment.ts
|
|
25379
25390
|
const environmentColors = [
|
|
25380
25391
|
import_picocolors.default.blue,
|
|
25381
25392
|
import_picocolors.default.magenta,
|
|
@@ -25459,7 +25470,7 @@ var BaseEnvironment = class extends PartialEnvironment {
|
|
|
25459
25470
|
}
|
|
25460
25471
|
};
|
|
25461
25472
|
//#endregion
|
|
25462
|
-
//#region ../../
|
|
25473
|
+
//#region ../../vite/packages/vite/src/node/server/searchRoot.ts
|
|
25463
25474
|
const ROOT_FILES = ["pnpm-workspace.yaml", "lerna.json"];
|
|
25464
25475
|
function hasWorkspacePackageJSON(root) {
|
|
25465
25476
|
const path = join(root, "package.json");
|
|
@@ -25497,7 +25508,7 @@ function searchForWorkspaceRoot(current, root = searchForPackageRoot(current)) {
|
|
|
25497
25508
|
return searchForWorkspaceRoot(dir, root);
|
|
25498
25509
|
}
|
|
25499
25510
|
//#endregion
|
|
25500
|
-
//#region ../../
|
|
25511
|
+
//#region ../../vite/packages/vite/src/node/plugins/manifest.ts
|
|
25501
25512
|
const endsWithJSRE = /\.[cm]?js$/;
|
|
25502
25513
|
function manifestPlugin() {
|
|
25503
25514
|
const getState = perEnvironmentState(() => {
|
|
@@ -25592,7 +25603,7 @@ function getChunkOriginalFileName(chunk, root, isLegacy) {
|
|
|
25592
25603
|
}
|
|
25593
25604
|
}
|
|
25594
25605
|
//#endregion
|
|
25595
|
-
//#region ../../
|
|
25606
|
+
//#region ../../vite/packages/vite/src/node/plugins/css.ts
|
|
25596
25607
|
var import_src = /* @__PURE__ */ __toESM(require_src(), 1);
|
|
25597
25608
|
const decoder = new TextDecoder();
|
|
25598
25609
|
const _cssConfigDefaults = Object.freeze({
|
|
@@ -27252,7 +27263,7 @@ const esMap = {
|
|
|
27252
27263
|
"opera121"
|
|
27253
27264
|
]
|
|
27254
27265
|
};
|
|
27255
|
-
const esRE = /es(
|
|
27266
|
+
const esRE = /es(6|\d{4})/;
|
|
27256
27267
|
const versionRE = /\d/;
|
|
27257
27268
|
const convertTargetsCache = /* @__PURE__ */ new Map();
|
|
27258
27269
|
const convertTargets = (esbuildTarget) => {
|
|
@@ -27263,7 +27274,7 @@ const convertTargets = (esbuildTarget) => {
|
|
|
27263
27274
|
const entriesWithoutES = arraify(esbuildTarget).flatMap((e) => {
|
|
27264
27275
|
const match = esRE.exec(e);
|
|
27265
27276
|
if (!match) return e;
|
|
27266
|
-
const year = Number(match[1]);
|
|
27277
|
+
const year = match[1] === "6" ? 2015 : Number(match[1]);
|
|
27267
27278
|
if (!esMap[year]) throw new Error(`Unsupported target "${e}"`);
|
|
27268
27279
|
return esMap[year];
|
|
27269
27280
|
});
|
|
@@ -27296,7 +27307,7 @@ function resolveLibCssFilename(libOptions, root, packageCache) {
|
|
|
27296
27307
|
return `${name}.css`;
|
|
27297
27308
|
}
|
|
27298
27309
|
//#endregion
|
|
27299
|
-
//#region ../../
|
|
27310
|
+
//#region ../../vite/packages/vite/src/node/plugins/modulePreloadPolyfill.ts
|
|
27300
27311
|
const modulePreloadPolyfillId = "vite/modulepreload-polyfill";
|
|
27301
27312
|
const resolvedModulePreloadPolyfillId = "\0" + modulePreloadPolyfillId + ".js";
|
|
27302
27313
|
function modulePreloadPolyfillPlugin(config) {
|
|
@@ -27320,7 +27331,7 @@ function modulePreloadPolyfillPlugin(config) {
|
|
|
27320
27331
|
};
|
|
27321
27332
|
}
|
|
27322
27333
|
//#endregion
|
|
27323
|
-
//#region ../../
|
|
27334
|
+
//#region ../../vite/packages/vite/src/node/plugins/html.ts
|
|
27324
27335
|
var import_escape_html = /* @__PURE__ */ __toESM(require_escape_html(), 1);
|
|
27325
27336
|
const htmlProxyRE = /[?&]html-proxy=?(?:&inline-css)?(?:&style-attr)?&index=(\d+)\.(?:js|css)$/;
|
|
27326
27337
|
const isHtmlProxyRE = /[?&]html-proxy\b/;
|
|
@@ -28052,7 +28063,7 @@ function incrementIndent(indent = "") {
|
|
|
28052
28063
|
return `${indent}${indent[0] === " " ? " " : " "}`;
|
|
28053
28064
|
}
|
|
28054
28065
|
//#endregion
|
|
28055
|
-
//#region ../../
|
|
28066
|
+
//#region ../../vite/packages/vite/src/node/plugins/define.ts
|
|
28056
28067
|
const nonJsRe = /\.json(?:$|\?)/;
|
|
28057
28068
|
const isNonJsRequest = (request) => nonJsRe.test(request);
|
|
28058
28069
|
const escapedDotRE = /(?<!\\)\\./g;
|
|
@@ -28186,7 +28197,7 @@ function handleDefineValue(value) {
|
|
|
28186
28197
|
return JSON.stringify(value);
|
|
28187
28198
|
}
|
|
28188
28199
|
//#endregion
|
|
28189
|
-
//#region ../../
|
|
28200
|
+
//#region ../../vite/packages/vite/src/node/plugins/clientInjections.ts
|
|
28190
28201
|
const normalizedClientEntry$1 = normalizePath$1(CLIENT_ENTRY);
|
|
28191
28202
|
const normalizedEnvEntry$1 = normalizePath$1(ENV_ENTRY);
|
|
28192
28203
|
/**
|
|
@@ -28267,7 +28278,7 @@ async function getHmrImplementation(config) {
|
|
|
28267
28278
|
return (await createClientConfigValueReplacer(config))(content).replace(/import\s*['"]@vite\/env['"]/, "");
|
|
28268
28279
|
}
|
|
28269
28280
|
//#endregion
|
|
28270
|
-
//#region ../../
|
|
28281
|
+
//#region ../../vite/packages/vite/src/node/ssr/fetchModule.ts
|
|
28271
28282
|
/**
|
|
28272
28283
|
* Fetch module information for Vite runner.
|
|
28273
28284
|
* @experimental
|
|
@@ -28343,7 +28354,7 @@ function inlineSourceMap(mod, result, startOffset) {
|
|
|
28343
28354
|
return result;
|
|
28344
28355
|
}
|
|
28345
28356
|
//#endregion
|
|
28346
|
-
//#region ../../
|
|
28357
|
+
//#region ../../vite/packages/vite/src/node/optimizer/optimizer.ts
|
|
28347
28358
|
const debug$9 = createDebugger("vite:deps");
|
|
28348
28359
|
/**
|
|
28349
28360
|
* The amount to wait for requests to register newly found dependencies before triggering
|
|
@@ -28710,7 +28721,7 @@ function findInteropMismatches(discovered, optimized) {
|
|
|
28710
28721
|
return needsInteropMismatch;
|
|
28711
28722
|
}
|
|
28712
28723
|
//#endregion
|
|
28713
|
-
//#region ../../
|
|
28724
|
+
//#region ../../vite/packages/vite/src/node/server/moduleGraph.ts
|
|
28714
28725
|
var EnvironmentModuleNode = class {
|
|
28715
28726
|
environment;
|
|
28716
28727
|
/**
|
|
@@ -29203,7 +29214,7 @@ function build_default$1(dir, opts = {}) {
|
|
|
29203
29214
|
};
|
|
29204
29215
|
}
|
|
29205
29216
|
//#endregion
|
|
29206
|
-
//#region ../../
|
|
29217
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/static.ts
|
|
29207
29218
|
const knownJavascriptExtensionRE = /\.(?:[tj]sx?|[cm][tj]s)$/;
|
|
29208
29219
|
const ERR_DENIED_FILE = "ERR_DENIED_FILE";
|
|
29209
29220
|
const sirvOptions = ({ config, getHeaders, disableFsServeCheck }) => {
|
|
@@ -29370,7 +29381,7 @@ function renderRestrictedErrorHTML(msg) {
|
|
|
29370
29381
|
`;
|
|
29371
29382
|
}
|
|
29372
29383
|
//#endregion
|
|
29373
|
-
//#region ../../
|
|
29384
|
+
//#region ../../vite/packages/vite/src/node/server/transformRequest.ts
|
|
29374
29385
|
var import_etag = /* @__PURE__ */ __toESM(require_etag(), 1);
|
|
29375
29386
|
const ERR_LOAD_URL = "ERR_LOAD_URL";
|
|
29376
29387
|
const ERR_LOAD_PUBLIC_URL = "ERR_LOAD_PUBLIC_URL";
|
|
@@ -29610,7 +29621,7 @@ function getModuleTypeFromId(id) {
|
|
|
29610
29621
|
}
|
|
29611
29622
|
}
|
|
29612
29623
|
//#endregion
|
|
29613
|
-
//#region ../../
|
|
29624
|
+
//#region ../../vite/packages/vite/src/node/server/warmup.ts
|
|
29614
29625
|
function warmupFiles(server, environment) {
|
|
29615
29626
|
const { root } = server.config;
|
|
29616
29627
|
mapFiles(environment.config.dev.warmup, root).then((files) => {
|
|
@@ -29660,7 +29671,7 @@ async function mapFiles(files, root) {
|
|
|
29660
29671
|
return result;
|
|
29661
29672
|
}
|
|
29662
29673
|
//#endregion
|
|
29663
|
-
//#region ../../
|
|
29674
|
+
//#region ../../vite/packages/vite/src/node/server/environment.ts
|
|
29664
29675
|
var DevEnvironment = class extends BaseEnvironment {
|
|
29665
29676
|
mode = "dev";
|
|
29666
29677
|
moduleGraph;
|
|
@@ -29858,7 +29869,7 @@ function setupOnCrawlEnd() {
|
|
|
29858
29869
|
};
|
|
29859
29870
|
}
|
|
29860
29871
|
//#endregion
|
|
29861
|
-
//#region ../../
|
|
29872
|
+
//#region ../../vite/packages/vite/src/node/server/environments/fullBundleEnvironment.ts
|
|
29862
29873
|
const debug$8 = createDebugger("vite:full-bundle-mode");
|
|
29863
29874
|
var MemoryFiles = class {
|
|
29864
29875
|
files = /* @__PURE__ */ new Map();
|
|
@@ -30027,7 +30038,8 @@ var FullBundleDevEnvironment = class extends DevEnvironment {
|
|
|
30027
30038
|
const rolldownOptions = resolveRolldownOptions(this, chunkMetadataMap);
|
|
30028
30039
|
rolldownOptions.experimental ??= {};
|
|
30029
30040
|
rolldownOptions.experimental.devMode = { implement: await getHmrImplementation(this.getTopLevelConfig()) };
|
|
30030
|
-
|
|
30041
|
+
rolldownOptions.optimization ??= {};
|
|
30042
|
+
rolldownOptions.optimization.inlineConst = false;
|
|
30031
30043
|
if (Array.isArray(rolldownOptions.output)) for (const output of rolldownOptions.output) {
|
|
30032
30044
|
output.entryFileNames = "assets/[name].js";
|
|
30033
30045
|
output.chunkFileNames = "assets/[name]-[hash].js";
|
|
@@ -30122,7 +30134,7 @@ function debounce(time, cb) {
|
|
|
30122
30134
|
};
|
|
30123
30135
|
}
|
|
30124
30136
|
//#endregion
|
|
30125
|
-
//#region ../../
|
|
30137
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/htmlFallback.ts
|
|
30126
30138
|
const debug$7 = createDebugger("vite:html-fallback");
|
|
30127
30139
|
function htmlFallbackMiddleware(root, spaFallback, clientEnvironment) {
|
|
30128
30140
|
const memoryFiles = clientEnvironment instanceof FullBundleDevEnvironment ? clientEnvironment.memoryFiles : void 0;
|
|
@@ -30165,7 +30177,7 @@ function htmlFallbackMiddleware(root, spaFallback, clientEnvironment) {
|
|
|
30165
30177
|
};
|
|
30166
30178
|
}
|
|
30167
30179
|
//#endregion
|
|
30168
|
-
//#region ../../
|
|
30180
|
+
//#region ../../vite/packages/vite/src/node/server/send.ts
|
|
30169
30181
|
const debug$6 = createDebugger("vite:send", { onlyWhenFocused: true });
|
|
30170
30182
|
const alias = {
|
|
30171
30183
|
js: "text/javascript",
|
|
@@ -30204,7 +30216,7 @@ function send(req, res, content, type, options) {
|
|
|
30204
30216
|
else res.end(content);
|
|
30205
30217
|
}
|
|
30206
30218
|
//#endregion
|
|
30207
|
-
//#region ../../
|
|
30219
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/transform.ts
|
|
30208
30220
|
const debugCache = createDebugger("vite:cache");
|
|
30209
30221
|
const knownIgnoreList = new Set(["/", "/favicon.ico"]);
|
|
30210
30222
|
const documentFetchDests = new Set([
|
|
@@ -30386,7 +30398,7 @@ If you intend to import that asset, put the file in the src directory, and use $
|
|
|
30386
30398
|
}
|
|
30387
30399
|
}
|
|
30388
30400
|
//#endregion
|
|
30389
|
-
//#region ../../
|
|
30401
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/indexHtml.ts
|
|
30390
30402
|
function createDevHtmlTransformFn(config) {
|
|
30391
30403
|
const [preHooks, normalHooks, postHooks] = resolveHtmlTransforms(config.plugins);
|
|
30392
30404
|
const transformHooks = [
|
|
@@ -30680,7 +30692,7 @@ async function generateFallbackHtml(server) {
|
|
|
30680
30692
|
`;
|
|
30681
30693
|
}
|
|
30682
30694
|
//#endregion
|
|
30683
|
-
//#region ../../
|
|
30695
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/time.ts
|
|
30684
30696
|
const logTime = createDebugger("vite:time");
|
|
30685
30697
|
function timeMiddleware(root) {
|
|
30686
30698
|
return function viteTimeMiddleware(req, res, next) {
|
|
@@ -30694,7 +30706,7 @@ function timeMiddleware(root) {
|
|
|
30694
30706
|
};
|
|
30695
30707
|
}
|
|
30696
30708
|
//#endregion
|
|
30697
|
-
//#region ../../
|
|
30709
|
+
//#region ../../vite/packages/vite/src/node/server/mixedModuleGraph.ts
|
|
30698
30710
|
/**
|
|
30699
30711
|
* Backward compatible ModuleNode and ModuleGraph with mixed nodes from both the client and ssr environments
|
|
30700
30712
|
* It would be good to take the types names for the new EnvironmentModuleNode and EnvironmentModuleGraph but we can't
|
|
@@ -31108,7 +31120,7 @@ function createBackwardCompatibleFileToModulesMap(moduleGraph) {
|
|
|
31108
31120
|
};
|
|
31109
31121
|
}
|
|
31110
31122
|
//#endregion
|
|
31111
|
-
//#region ../../
|
|
31123
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/notFound.ts
|
|
31112
31124
|
function notFoundMiddleware() {
|
|
31113
31125
|
return function vite404Middleware(_, res) {
|
|
31114
31126
|
res.statusCode = 404;
|
|
@@ -31116,7 +31128,7 @@ function notFoundMiddleware() {
|
|
|
31116
31128
|
};
|
|
31117
31129
|
}
|
|
31118
31130
|
//#endregion
|
|
31119
|
-
//#region ../../
|
|
31131
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/hostCheck.ts
|
|
31120
31132
|
function getAdditionalAllowedHosts(resolvedServerOptions, resolvedPreviewOptions) {
|
|
31121
31133
|
const list = [];
|
|
31122
31134
|
if (typeof resolvedServerOptions.host === "string" && resolvedServerOptions.host) list.push(resolvedServerOptions.host);
|
|
@@ -31138,7 +31150,7 @@ function hostValidationMiddleware(allowedHosts, isPreview) {
|
|
|
31138
31150
|
});
|
|
31139
31151
|
}
|
|
31140
31152
|
//#endregion
|
|
31141
|
-
//#region ../../
|
|
31153
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/rejectInvalidRequest.ts
|
|
31142
31154
|
/**
|
|
31143
31155
|
* disallows request that contains `#` in the URL
|
|
31144
31156
|
*/
|
|
@@ -31153,7 +31165,7 @@ function rejectInvalidRequestMiddleware() {
|
|
|
31153
31165
|
};
|
|
31154
31166
|
}
|
|
31155
31167
|
//#endregion
|
|
31156
|
-
//#region ../../
|
|
31168
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/memoryFiles.ts
|
|
31157
31169
|
function memoryFilesMiddleware(server) {
|
|
31158
31170
|
const memoryFiles = server.environments.client instanceof FullBundleDevEnvironment ? server.environments.client.memoryFiles : void 0;
|
|
31159
31171
|
if (!memoryFiles) throw new Error("memoryFilesMiddleware can only be used for fullBundleMode");
|
|
@@ -31181,7 +31193,7 @@ function memoryFilesMiddleware(server) {
|
|
|
31181
31193
|
};
|
|
31182
31194
|
}
|
|
31183
31195
|
//#endregion
|
|
31184
|
-
//#region ../../
|
|
31196
|
+
//#region ../../vite/packages/vite/src/node/server/middlewares/rejectNoCorsRequest.ts
|
|
31185
31197
|
/**
|
|
31186
31198
|
* A middleware that rejects no-cors mode requests that are not same-origin.
|
|
31187
31199
|
*
|
|
@@ -31199,15 +31211,15 @@ function memoryFilesMiddleware(server) {
|
|
|
31199
31211
|
function rejectNoCorsRequestMiddleware() {
|
|
31200
31212
|
return function viteRejectNoCorsRequestMiddleware(req, res, next) {
|
|
31201
31213
|
if (req.headers["sec-fetch-mode"] === "no-cors" && req.headers["sec-fetch-site"] !== "same-origin" && req.headers["sec-fetch-dest"] === "script") {
|
|
31202
|
-
res.
|
|
31203
|
-
res.end("Cross-origin requests for classic scripts must be made with CORS mode enabled. Make sure to set the \"crossorigin\" attribute on your <script> tag.");
|
|
31214
|
+
res.setHeader("Content-Type", "text/javascript");
|
|
31215
|
+
res.end(`throw new Error(${JSON.stringify("[Vite] Cross-origin requests for classic scripts must be made with CORS mode enabled. Make sure to set the \"crossorigin\" attribute on your <script> tag.")});`);
|
|
31204
31216
|
return;
|
|
31205
31217
|
}
|
|
31206
31218
|
return next();
|
|
31207
31219
|
};
|
|
31208
31220
|
}
|
|
31209
31221
|
//#endregion
|
|
31210
|
-
//#region ../../
|
|
31222
|
+
//#region ../../vite/packages/vite/src/node/server/index.ts
|
|
31211
31223
|
var import_connect = /* @__PURE__ */ __toESM(require_connect(), 1);
|
|
31212
31224
|
var import_lib = /* @__PURE__ */ __toESM(require_lib$1(), 1);
|
|
31213
31225
|
var import_chokidar = /* @__PURE__ */ __toESM(require_chokidar(), 1);
|
|
@@ -31268,10 +31280,9 @@ async function _createServer(inlineConfig = {}, options) {
|
|
|
31268
31280
|
await Promise.all(Object.entries(config.environments).map(async ([name, environmentOptions]) => {
|
|
31269
31281
|
const environment = await environmentOptions.dev.createEnvironment(name, config, { ws });
|
|
31270
31282
|
environments[name] = environment;
|
|
31271
|
-
const previousInstance = options.previousEnvironments?.[environment.name];
|
|
31272
31283
|
await environment.init({
|
|
31273
31284
|
watcher,
|
|
31274
|
-
previousInstance
|
|
31285
|
+
previousInstance: options.previousEnvironments?.[environment.name]
|
|
31275
31286
|
});
|
|
31276
31287
|
}));
|
|
31277
31288
|
let moduleGraph = new ModuleGraph({
|
|
@@ -31409,8 +31420,8 @@ async function _createServer(inlineConfig = {}, options) {
|
|
|
31409
31420
|
_setInternalServer(_server) {
|
|
31410
31421
|
server = _server;
|
|
31411
31422
|
},
|
|
31412
|
-
_restartPromise: null,
|
|
31413
|
-
_forceOptimizeOnRestart: false,
|
|
31423
|
+
_restartPromise: options.previousRestartPromise ?? null,
|
|
31424
|
+
_forceOptimizeOnRestart: options.previousForceOptimizeOnRestart ?? false,
|
|
31414
31425
|
_shortcutsState: options.previousShortcutsState
|
|
31415
31426
|
};
|
|
31416
31427
|
const reflexServer = new Proxy(server, {
|
|
@@ -31652,7 +31663,9 @@ async function restartServer(server) {
|
|
|
31652
31663
|
newServer = await _createServer(inlineConfig, {
|
|
31653
31664
|
listen: false,
|
|
31654
31665
|
previousEnvironments: server.environments,
|
|
31655
|
-
previousShortcutsState: server._shortcutsState
|
|
31666
|
+
previousShortcutsState: server._shortcutsState,
|
|
31667
|
+
previousRestartPromise: server._restartPromise,
|
|
31668
|
+
previousForceOptimizeOnRestart: server._forceOptimizeOnRestart
|
|
31656
31669
|
});
|
|
31657
31670
|
} catch (err) {
|
|
31658
31671
|
server.config.logger.error(err.message, { timestamp: true });
|
|
@@ -31664,8 +31677,6 @@ async function restartServer(server) {
|
|
|
31664
31677
|
const middlewares = server.middlewares;
|
|
31665
31678
|
newServer._configServerPort = server._configServerPort;
|
|
31666
31679
|
newServer._currentServerPort = server._currentServerPort;
|
|
31667
|
-
newServer._restartPromise = server._restartPromise;
|
|
31668
|
-
newServer._forceOptimizeOnRestart = server._forceOptimizeOnRestart;
|
|
31669
31680
|
Object.assign(server, newServer);
|
|
31670
31681
|
middlewares.stack = newServer.middlewares.stack;
|
|
31671
31682
|
server.middlewares = middlewares;
|
|
@@ -31695,7 +31706,7 @@ async function restartServerWithUrls(server) {
|
|
|
31695
31706
|
}
|
|
31696
31707
|
}
|
|
31697
31708
|
//#endregion
|
|
31698
|
-
//#region ../../
|
|
31709
|
+
//#region ../../vite/packages/vite/src/node/server/hmr.ts
|
|
31699
31710
|
const debugHmr = createDebugger("vite:hmr");
|
|
31700
31711
|
const whitespaceRE = /\s/;
|
|
31701
31712
|
const normalizedClientDir = normalizePath$1(CLIENT_DIR);
|
|
@@ -32235,7 +32246,7 @@ function createServerHotChannel() {
|
|
|
32235
32246
|
};
|
|
32236
32247
|
}
|
|
32237
32248
|
//#endregion
|
|
32238
|
-
//#region ../../
|
|
32249
|
+
//#region ../../vite/packages/vite/src/node/external.ts
|
|
32239
32250
|
const debug$5 = createDebugger("vite:external");
|
|
32240
32251
|
const isExternalCache = /* @__PURE__ */ new WeakMap();
|
|
32241
32252
|
function shouldExternalize(environment, id, importer) {
|
|
@@ -32297,7 +32308,7 @@ function canExternalizeFile(filePath) {
|
|
|
32297
32308
|
return !ext || ext === ".js" || ext === ".mjs" || ext === ".cjs";
|
|
32298
32309
|
}
|
|
32299
32310
|
//#endregion
|
|
32300
|
-
//#region ../../
|
|
32311
|
+
//#region ../../vite/packages/vite/src/node/plugins/worker.ts
|
|
32301
32312
|
var WorkerOutputCache = class {
|
|
32302
32313
|
/**
|
|
32303
32314
|
* worker bundle information for each input id
|
|
@@ -32389,7 +32400,11 @@ async function bundleWorkerEntry(config, id) {
|
|
|
32389
32400
|
".css": "js",
|
|
32390
32401
|
...rollupOptions.moduleTypes
|
|
32391
32402
|
},
|
|
32392
|
-
preserveEntrySignatures: false
|
|
32403
|
+
preserveEntrySignatures: false,
|
|
32404
|
+
experimental: {
|
|
32405
|
+
...rollupOptions.experimental,
|
|
32406
|
+
viteMode: true
|
|
32407
|
+
}
|
|
32393
32408
|
});
|
|
32394
32409
|
let result;
|
|
32395
32410
|
let watchedFiles;
|
|
@@ -32400,10 +32415,10 @@ async function bundleWorkerEntry(config, id) {
|
|
|
32400
32415
|
entryFileNames: path.posix.join(config.build.assetsDir, "[name]-[hash].js"),
|
|
32401
32416
|
chunkFileNames: path.posix.join(config.build.assetsDir, "[name]-[hash].js"),
|
|
32402
32417
|
assetFileNames: path.posix.join(config.build.assetsDir, "[name]-[hash].[ext]"),
|
|
32403
|
-
minify: config.build.minify === "oxc" ? true : config.build.minify === false ? "dce-only" : void 0,
|
|
32418
|
+
minify: workerEnvironment.config.build.minify === "oxc" ? true : workerEnvironment.config.build.minify === false ? "dce-only" : void 0,
|
|
32404
32419
|
...workerConfig,
|
|
32405
32420
|
format,
|
|
32406
|
-
sourcemap: config.build.sourcemap
|
|
32421
|
+
sourcemap: workerEnvironment.config.build.sourcemap
|
|
32407
32422
|
});
|
|
32408
32423
|
watchedFiles = (await bundle.watchFiles).map((f) => normalizePath$1(f));
|
|
32409
32424
|
} catch (e) {
|
|
@@ -32653,7 +32668,7 @@ function isSameContent(a, b) {
|
|
|
32653
32668
|
return Buffer.from(b).equals(a);
|
|
32654
32669
|
}
|
|
32655
32670
|
//#endregion
|
|
32656
|
-
//#region ../../
|
|
32671
|
+
//#region ../../vite/packages/vite/src/node/plugins/preAlias.ts
|
|
32657
32672
|
/**
|
|
32658
32673
|
* A plugin to avoid an aliased AND optimized dep from being aliased in src
|
|
32659
32674
|
*/
|
|
@@ -32707,7 +32722,7 @@ function getAliasPatternMatcher(entries) {
|
|
|
32707
32722
|
return (importee) => patterns.some((pattern) => matches(pattern, importee));
|
|
32708
32723
|
}
|
|
32709
32724
|
//#endregion
|
|
32710
|
-
//#region ../../
|
|
32725
|
+
//#region ../../vite/packages/vite/src/node/plugins/importAnalysis.ts
|
|
32711
32726
|
const debug$4 = createDebugger("vite:import-analysis");
|
|
32712
32727
|
const clientDir = normalizePath$1(CLIENT_DIR);
|
|
32713
32728
|
const skipRE = /\.(?:map|json)(?:$|\?)/;
|
|
@@ -33130,7 +33145,7 @@ function __vite__injectQuery(url, queryToInject) {
|
|
|
33130
33145
|
return `${pathname}?${queryToInject}${search ? `&` + search.slice(1) : ""}${hash || ""}`;
|
|
33131
33146
|
}
|
|
33132
33147
|
//#endregion
|
|
33133
|
-
//#region ../../
|
|
33148
|
+
//#region ../../vite/packages/vite/src/node/plugins/wasm.ts
|
|
33134
33149
|
const wasmHelperId = "\0vite/wasm-helper.js";
|
|
33135
33150
|
const wasmInitRE = /(?<![?#].*)\.wasm\?init/;
|
|
33136
33151
|
const wasmInitUrlRE = /__VITE_WASM_INIT__([\w$]+)__/g;
|
|
@@ -33224,7 +33239,7 @@ export default ${wasmHelperCode}
|
|
|
33224
33239
|
});
|
|
33225
33240
|
};
|
|
33226
33241
|
//#endregion
|
|
33227
|
-
//#region ../../
|
|
33242
|
+
//#region ../../vite/packages/vite/src/node/plugins/workerImportMetaUrl.ts
|
|
33228
33243
|
function err$1(e, pos) {
|
|
33229
33244
|
const error = new Error(e);
|
|
33230
33245
|
error.pos = pos;
|
|
@@ -33289,7 +33304,7 @@ async function getWorkerType(raw, clean, i) {
|
|
|
33289
33304
|
if (workerOpts.type && (workerOpts.type === "module" || workerOpts.type === "classic")) return workerOpts.type;
|
|
33290
33305
|
return "classic";
|
|
33291
33306
|
}
|
|
33292
|
-
const workerImportMetaUrlRE =
|
|
33307
|
+
const workerImportMetaUrlRE = /\bnew\s+(?:Worker|SharedWorker)\s*\(\s*(new\s+URL\s*\(\s*('[^']+'|"[^"]+"|`[^`]+`)\s*,\s*import\.meta\.url\s*(?:,\s*)?\))/dg;
|
|
33293
33308
|
function workerImportMetaUrlPlugin(config) {
|
|
33294
33309
|
const isBundled = config.isBundled;
|
|
33295
33310
|
let workerResolver;
|
|
@@ -33311,9 +33326,9 @@ function workerImportMetaUrlPlugin(config) {
|
|
|
33311
33326
|
async handler(code, id) {
|
|
33312
33327
|
let s;
|
|
33313
33328
|
const cleanString = stripLiteral(code);
|
|
33314
|
-
const
|
|
33329
|
+
const re = new RegExp(workerImportMetaUrlRE);
|
|
33315
33330
|
let match;
|
|
33316
|
-
while (match =
|
|
33331
|
+
while (match = re.exec(cleanString)) {
|
|
33317
33332
|
const [[, endIndex], [expStart, expEnd], [urlStart, urlEnd]] = match.indices;
|
|
33318
33333
|
const rawUrl = code.slice(urlStart, urlEnd);
|
|
33319
33334
|
if (rawUrl[0] === "`" && rawUrl.includes("${")) this.error(`\`new URL(url, import.meta.url)\` is not supported in dynamic template string.`, expStart);
|
|
@@ -33355,7 +33370,7 @@ function workerImportMetaUrlPlugin(config) {
|
|
|
33355
33370
|
};
|
|
33356
33371
|
}
|
|
33357
33372
|
//#endregion
|
|
33358
|
-
//#region ../../
|
|
33373
|
+
//#region ../../vite/packages/vite/src/node/plugins/importAnalysisBuild.ts
|
|
33359
33374
|
/**
|
|
33360
33375
|
* A flag for injected helpers. This flag will be set to `false` if the output
|
|
33361
33376
|
* target is not native es - so that injected helper logic can be conditionally
|
|
@@ -33651,7 +33666,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
33651
33666
|
})];
|
|
33652
33667
|
}
|
|
33653
33668
|
//#endregion
|
|
33654
|
-
//#region ../../
|
|
33669
|
+
//#region ../../vite/packages/vite/src/node/plugins/assetImportMetaUrl.ts
|
|
33655
33670
|
/**
|
|
33656
33671
|
* Convert `new URL('./foo.png', import.meta.url)` to its resolved built URL
|
|
33657
33672
|
*
|
|
@@ -33662,6 +33677,7 @@ function buildImportAnalysisPlugin(config) {
|
|
|
33662
33677
|
* import.meta.glob('./dir/**.png', { eager: true, import: 'default' })[`./dir/${name}.png`]
|
|
33663
33678
|
* ```
|
|
33664
33679
|
*/
|
|
33680
|
+
const assetImportMetaUrlRE = /\bnew\s+URL\s*\(\s*('[^']+'|"[^"]+"|`[^`]+`)\s*,\s*import\.meta\.url\s*(?:,\s*)?\)/dg;
|
|
33665
33681
|
function assetImportMetaUrlPlugin(config) {
|
|
33666
33682
|
const { publicDir } = config;
|
|
33667
33683
|
let assetResolver;
|
|
@@ -33681,14 +33697,14 @@ function assetImportMetaUrlPlugin(config) {
|
|
|
33681
33697
|
transform: {
|
|
33682
33698
|
filter: {
|
|
33683
33699
|
id: { exclude: [exactRegex(preloadHelperId), exactRegex(CLIENT_ENTRY)] },
|
|
33684
|
-
code:
|
|
33700
|
+
code: assetImportMetaUrlRE
|
|
33685
33701
|
},
|
|
33686
33702
|
async handler(code, id) {
|
|
33687
33703
|
let s;
|
|
33688
|
-
const
|
|
33704
|
+
const re = new RegExp(assetImportMetaUrlRE);
|
|
33689
33705
|
const cleanString = stripLiteral(code);
|
|
33690
33706
|
let match;
|
|
33691
|
-
while (match =
|
|
33707
|
+
while (match = re.exec(cleanString)) {
|
|
33692
33708
|
const [[startIndex, endIndex], [urlStart, urlEnd]] = match.indices;
|
|
33693
33709
|
if (hasViteIgnoreRE.test(code.slice(startIndex, urlStart))) continue;
|
|
33694
33710
|
const rawUrl = code.slice(urlStart, urlEnd);
|
|
@@ -33831,7 +33847,7 @@ function dynamicImportToGlob(node, sourceString) {
|
|
|
33831
33847
|
return glob;
|
|
33832
33848
|
}
|
|
33833
33849
|
//#endregion
|
|
33834
|
-
//#region ../../
|
|
33850
|
+
//#region ../../vite/packages/vite/src/node/plugins/dynamicImportVars.ts
|
|
33835
33851
|
const dynamicImportHelperId = "\0vite/dynamic-import-helper.js";
|
|
33836
33852
|
const relativePathRE = /^\.{1,2}\//;
|
|
33837
33853
|
const hasDynamicImportRE = /\bimport\s*[(/]/;
|
|
@@ -33964,7 +33980,7 @@ function dynamicImportVarsPlugin(config) {
|
|
|
33964
33980
|
};
|
|
33965
33981
|
}
|
|
33966
33982
|
//#endregion
|
|
33967
|
-
//#region ../../
|
|
33983
|
+
//#region ../../vite/packages/vite/src/node/plugins/importMetaGlob.ts
|
|
33968
33984
|
function importGlobPlugin(config) {
|
|
33969
33985
|
if (config.isBundled) return viteImportGlobPlugin({
|
|
33970
33986
|
root: config.root,
|
|
@@ -34301,7 +34317,7 @@ function isVirtualModule(id) {
|
|
|
34301
34317
|
return id.startsWith("virtual:") || id[0] === "\0" || !id.includes("/");
|
|
34302
34318
|
}
|
|
34303
34319
|
//#endregion
|
|
34304
|
-
//#region ../../
|
|
34320
|
+
//#region ../../vite/packages/vite/src/node/plugins/pluginFilter.ts
|
|
34305
34321
|
function getMatcherString(glob, cwd) {
|
|
34306
34322
|
if (glob.startsWith("**") || path.isAbsolute(glob)) return slash(glob);
|
|
34307
34323
|
return slash(path.join(cwd, glob));
|
|
@@ -34376,7 +34392,7 @@ function createFilterForTransform(idFilter, codeFilter, moduleTypeFilter, cwd) {
|
|
|
34376
34392
|
};
|
|
34377
34393
|
}
|
|
34378
34394
|
//#endregion
|
|
34379
|
-
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0
|
|
34395
|
+
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0/node_modules/@vitest/utils/dist/helpers.js
|
|
34380
34396
|
function notNullish(v) {
|
|
34381
34397
|
return v != null;
|
|
34382
34398
|
}
|
|
@@ -34384,7 +34400,7 @@ function isPrimitive(value) {
|
|
|
34384
34400
|
return value === null || typeof value !== "function" && typeof value !== "object";
|
|
34385
34401
|
}
|
|
34386
34402
|
//#endregion
|
|
34387
|
-
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0
|
|
34403
|
+
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0/node_modules/@vitest/utils/dist/chunk-pathe.M-eThtNZ.js
|
|
34388
34404
|
const _DRIVE_LETTER_START_RE = /^[A-Za-z]:\//;
|
|
34389
34405
|
function normalizeWindowsPath(input = "") {
|
|
34390
34406
|
if (!input) return input;
|
|
@@ -34463,7 +34479,7 @@ const isAbsolute$2 = function(p) {
|
|
|
34463
34479
|
return _IS_ABSOLUTE_RE.test(p);
|
|
34464
34480
|
};
|
|
34465
34481
|
//#endregion
|
|
34466
|
-
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0
|
|
34482
|
+
//#region ../../node_modules/.pnpm/@vitest+utils@4.1.0/node_modules/@vitest/utils/dist/source-map.js
|
|
34467
34483
|
var comma = ",".charCodeAt(0);
|
|
34468
34484
|
var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
34469
34485
|
var intToChar = new Uint8Array(64);
|
|
@@ -34826,7 +34842,7 @@ function getOriginalPosition(map, needle) {
|
|
|
34826
34842
|
return result;
|
|
34827
34843
|
}
|
|
34828
34844
|
//#endregion
|
|
34829
|
-
//#region ../../
|
|
34845
|
+
//#region ../../vite/packages/vite/src/node/plugins/forwardConsole.ts
|
|
34830
34846
|
function forwardConsolePlugin(pluginOpts) {
|
|
34831
34847
|
const sourceMapCache = /* @__PURE__ */ new Map();
|
|
34832
34848
|
return {
|
|
@@ -34896,7 +34912,7 @@ function formatError(payload, environment, sourceMapCache) {
|
|
|
34896
34912
|
return output;
|
|
34897
34913
|
}
|
|
34898
34914
|
//#endregion
|
|
34899
|
-
//#region ../../
|
|
34915
|
+
//#region ../../vite/packages/vite/src/node/plugins/esbuildBannerFooterCompatPlugin.ts
|
|
34900
34916
|
/**
|
|
34901
34917
|
* This plugin supports `esbuild.banner` and `esbuild.footer` options.
|
|
34902
34918
|
* esbuild supported these options and Vite exposed them.
|
|
@@ -34931,7 +34947,7 @@ function esbuildBannerFooterCompatPlugin(config) {
|
|
|
34931
34947
|
};
|
|
34932
34948
|
}
|
|
34933
34949
|
//#endregion
|
|
34934
|
-
//#region ../../
|
|
34950
|
+
//#region ../../vite/packages/vite/src/node/plugins/index.ts
|
|
34935
34951
|
async function resolvePlugins(config, prePlugins, normalPlugins, postPlugins) {
|
|
34936
34952
|
const isBuild = config.command === "build";
|
|
34937
34953
|
const isBundled = config.isBundled;
|
|
@@ -34973,6 +34989,7 @@ async function resolvePlugins(config, prePlugins, normalPlugins, postPlugins) {
|
|
|
34973
34989
|
htmlInlineProxyPlugin(config),
|
|
34974
34990
|
cssPlugin(config),
|
|
34975
34991
|
esbuildBannerFooterCompatPlugin(config),
|
|
34992
|
+
config.oxc !== false && !isBundled ? oxcRuntimePlugin() : null,
|
|
34976
34993
|
config.oxc !== false ? oxcPlugin(config) : null,
|
|
34977
34994
|
viteJsonPlugin({
|
|
34978
34995
|
...config.json,
|
|
@@ -35082,7 +35099,7 @@ const viteAliasCustomResolver = async function(id, importer, options) {
|
|
|
35082
35099
|
};
|
|
35083
35100
|
};
|
|
35084
35101
|
//#endregion
|
|
35085
|
-
//#region ../../
|
|
35102
|
+
//#region ../../vite/packages/vite/src/node/server/pluginContainer.ts
|
|
35086
35103
|
/**
|
|
35087
35104
|
* This file is refactored into TypeScript based on
|
|
35088
35105
|
* https://github.com/preactjs/wmr/blob/main/packages/wmr/src/lib/rollup-plugin-container.js
|
|
@@ -35796,7 +35813,7 @@ function createPluginContainer(environments) {
|
|
|
35796
35813
|
return new PluginContainer(environments);
|
|
35797
35814
|
}
|
|
35798
35815
|
//#endregion
|
|
35799
|
-
//#region ../../
|
|
35816
|
+
//#region ../../vite/packages/vite/src/node/optimizer/scan.ts
|
|
35800
35817
|
var ScanEnvironment = class extends BaseEnvironment {
|
|
35801
35818
|
mode = "scan";
|
|
35802
35819
|
get pluginContainer() {
|
|
@@ -36005,10 +36022,8 @@ function rolldownScanPlugin(environment, depImports, missing, entries) {
|
|
|
36005
36022
|
if (lang === "ts" || lang === "tsx" || lang === "jsx") loader = lang;
|
|
36006
36023
|
else if (id.endsWith(".astro")) loader = "ts";
|
|
36007
36024
|
const srcMatch = srcRE.exec(openTag);
|
|
36008
|
-
if (srcMatch) {
|
|
36009
|
-
|
|
36010
|
-
js += `import ${JSON.stringify(src)}\n`;
|
|
36011
|
-
} else if (content.trim()) {
|
|
36025
|
+
if (srcMatch) js += `import ${JSON.stringify(srcMatch[1] || srcMatch[2] || srcMatch[3])}\n`;
|
|
36026
|
+
else if (content.trim()) {
|
|
36012
36027
|
const contents = content + (loader.startsWith("ts") ? extractImportPaths(content) : "");
|
|
36013
36028
|
const key = `${id}?id=${scriptId++}`;
|
|
36014
36029
|
if (contents.includes("import.meta.glob")) scripts[key] = {
|
|
@@ -36181,7 +36196,7 @@ function isScannable(id, extensions) {
|
|
|
36181
36196
|
return JS_TYPES_RE.test(id) || htmlTypesRE.test(id) || extensions?.includes(path.extname(id)) || false;
|
|
36182
36197
|
}
|
|
36183
36198
|
//#endregion
|
|
36184
|
-
//#region ../../
|
|
36199
|
+
//#region ../../vite/packages/vite/src/node/optimizer/resolve.ts
|
|
36185
36200
|
function createOptimizeDepsIncludeResolver(environment) {
|
|
36186
36201
|
const topLevelConfig = environment.getTopLevelConfig();
|
|
36187
36202
|
const resolve = createBackCompatIdResolver(topLevelConfig, {
|
|
@@ -36265,7 +36280,7 @@ function nestedResolveBasedir(id, basedir, preserveSymlinks = false) {
|
|
|
36265
36280
|
return basedir;
|
|
36266
36281
|
}
|
|
36267
36282
|
//#endregion
|
|
36268
|
-
//#region ../../
|
|
36283
|
+
//#region ../../vite/packages/vite/src/node/optimizer/rolldownDepPlugin.ts
|
|
36269
36284
|
const externalWithConversionNamespace = "vite:dep-pre-bundle:external-conversion";
|
|
36270
36285
|
const convertedExternalPrefix = "vite-dep-pre-bundle-external:";
|
|
36271
36286
|
const cjsExternalFacadeNamespace = "vite:cjs-external-facade";
|
|
@@ -36415,13 +36430,13 @@ function rolldownDepPlugin(environment, qualified, external) {
|
|
|
36415
36430
|
}
|
|
36416
36431
|
},
|
|
36417
36432
|
transform: {
|
|
36418
|
-
filter: { code:
|
|
36433
|
+
filter: { code: assetImportMetaUrlRE },
|
|
36419
36434
|
async handler(code, id) {
|
|
36420
36435
|
let s;
|
|
36421
|
-
const
|
|
36436
|
+
const re = new RegExp(assetImportMetaUrlRE);
|
|
36422
36437
|
const cleanString = stripLiteral(code);
|
|
36423
36438
|
let match;
|
|
36424
|
-
while (match =
|
|
36439
|
+
while (match = re.exec(cleanString)) {
|
|
36425
36440
|
const [[startIndex, endIndex], [urlStart, urlEnd]] = match.indices;
|
|
36426
36441
|
if (hasViteIgnoreRE.test(code.slice(startIndex, urlStart))) continue;
|
|
36427
36442
|
const rawUrl = code.slice(urlStart, urlEnd);
|
|
@@ -36475,7 +36490,7 @@ module.exports = ${isNodeBuiltin(idWithoutNamespace) ? "m.default" : "{ ...m }"}
|
|
|
36475
36490
|
};
|
|
36476
36491
|
}
|
|
36477
36492
|
//#endregion
|
|
36478
|
-
//#region ../../
|
|
36493
|
+
//#region ../../vite/packages/vite/src/node/optimizer/index.ts
|
|
36479
36494
|
const debug$2 = createDebugger("vite:deps");
|
|
36480
36495
|
const jsExtensionRE = /\.js$/i;
|
|
36481
36496
|
function isDepOptimizationDisabled(optimizeDeps) {
|
|
@@ -37158,7 +37173,7 @@ const safeRename = promisify(function gracefulRename(from, to, cb) {
|
|
|
37158
37173
|
});
|
|
37159
37174
|
});
|
|
37160
37175
|
//#endregion
|
|
37161
|
-
//#region ../../
|
|
37176
|
+
//#region ../../vite/packages/vite/src/node/plugins/resolve.ts
|
|
37162
37177
|
const normalizedClientEntry = normalizePath$1(CLIENT_ENTRY);
|
|
37163
37178
|
const normalizedEnvEntry = normalizePath$1(ENV_ENTRY);
|
|
37164
37179
|
const ERR_RESOLVE_PACKAGE_ENTRY_FAIL = "ERR_RESOLVE_PACKAGE_ENTRY_FAIL";
|
|
@@ -37632,7 +37647,7 @@ function findNearestPackagePath(file, legacyInconsistentCjsInterop, packageCache
|
|
|
37632
37647
|
return pkgData ? path.join(pkgData.dir, "package.json") : null;
|
|
37633
37648
|
}
|
|
37634
37649
|
//#endregion
|
|
37635
|
-
//#region ../../
|
|
37650
|
+
//#region ../../vite/packages/vite/src/node/nodeResolve.ts
|
|
37636
37651
|
/**
|
|
37637
37652
|
* Resolve like Node.js using Vite's resolution algorithm with preconfigured options.
|
|
37638
37653
|
*/
|
|
@@ -37659,7 +37674,7 @@ function nodeResolveWithVite(id, importer, options) {
|
|
|
37659
37674
|
})?.id;
|
|
37660
37675
|
}
|
|
37661
37676
|
//#endregion
|
|
37662
|
-
//#region ../../
|
|
37677
|
+
//#region ../../vite/packages/vite/src/node/plugins/terser.ts
|
|
37663
37678
|
let terserPath;
|
|
37664
37679
|
function loadTerserPath(root) {
|
|
37665
37680
|
if (terserPath) return terserPath;
|
|
@@ -37727,7 +37742,7 @@ function terserPlugin(config) {
|
|
|
37727
37742
|
};
|
|
37728
37743
|
}
|
|
37729
37744
|
//#endregion
|
|
37730
|
-
//#region ../../
|
|
37745
|
+
//#region ../../vite/packages/vite/src/node/ssr/ssrManifestPlugin.ts
|
|
37731
37746
|
function ssrManifestPlugin() {
|
|
37732
37747
|
const getSsrManifest = perEnvironmentState(() => {
|
|
37733
37748
|
return {};
|
|
@@ -37811,7 +37826,7 @@ function ssrManifestPlugin() {
|
|
|
37811
37826
|
};
|
|
37812
37827
|
}
|
|
37813
37828
|
//#endregion
|
|
37814
|
-
//#region ../../
|
|
37829
|
+
//#region ../../vite/packages/vite/src/node/plugins/license.ts
|
|
37815
37830
|
const licenseConfigDefaults = Object.freeze({ fileName: ".vite/license.md" });
|
|
37816
37831
|
const licenseFiles = [
|
|
37817
37832
|
/^license/i,
|
|
@@ -37889,7 +37904,7 @@ function findLicenseFile(pkgDir) {
|
|
|
37889
37904
|
if (matchedFile) return path.join(pkgDir, matchedFile);
|
|
37890
37905
|
}
|
|
37891
37906
|
//#endregion
|
|
37892
|
-
//#region ../../
|
|
37907
|
+
//#region ../../vite/packages/vite/src/node/plugins/prepareOutDir.ts
|
|
37893
37908
|
function prepareOutDirPlugin() {
|
|
37894
37909
|
const rendered = /* @__PURE__ */ new Set();
|
|
37895
37910
|
return {
|
|
@@ -37933,7 +37948,7 @@ function areSeparateFolders(a, b) {
|
|
|
37933
37948
|
return na !== nb && !na.startsWith(withTrailingSlash(nb)) && !nb.startsWith(withTrailingSlash(na));
|
|
37934
37949
|
}
|
|
37935
37950
|
//#endregion
|
|
37936
|
-
//#region ../../
|
|
37951
|
+
//#region ../../vite/packages/vite/src/node/build.ts
|
|
37937
37952
|
const _buildEnvironmentOptionsDefaults = Object.freeze({
|
|
37938
37953
|
target: "baseline-widely-available",
|
|
37939
37954
|
polyfillModulePreload: true,
|
|
@@ -38632,7 +38647,7 @@ async function createBuilder(inlineConfig = {}, useLegacyBuilder = false) {
|
|
|
38632
38647
|
return builder;
|
|
38633
38648
|
}
|
|
38634
38649
|
//#endregion
|
|
38635
|
-
//#region ../../
|
|
38650
|
+
//#region ../../vite/packages/vite/src/node/server/environments/runnableEnvironment.ts
|
|
38636
38651
|
function createRunnableDevEnvironment(name, config, context = {}) {
|
|
38637
38652
|
if (context.transport == null) context.transport = createServerHotChannel();
|
|
38638
38653
|
if (context.hot == null) context.hot = true;
|
|
@@ -38744,7 +38759,7 @@ function build_default({ threshold = 1024, level = -1, brotli = false, gzip = tr
|
|
|
38744
38759
|
};
|
|
38745
38760
|
}
|
|
38746
38761
|
//#endregion
|
|
38747
|
-
//#region ../../
|
|
38762
|
+
//#region ../../vite/packages/vite/src/node/preview.ts
|
|
38748
38763
|
function resolvePreviewOptions(preview, server) {
|
|
38749
38764
|
return {
|
|
38750
38765
|
port: preview?.port ?? 4173,
|
|
@@ -38855,7 +38870,7 @@ async function preview(inlineConfig = {}) {
|
|
|
38855
38870
|
return server;
|
|
38856
38871
|
}
|
|
38857
38872
|
//#endregion
|
|
38858
|
-
//#region ../../
|
|
38873
|
+
//#region ../../vite/packages/vite/src/node/ssr/index.ts
|
|
38859
38874
|
const _ssrConfigDefaults = Object.freeze({
|
|
38860
38875
|
target: "node",
|
|
38861
38876
|
optimizeDeps: {}
|
|
@@ -38865,7 +38880,7 @@ function resolveSSROptions(ssr, preserveSymlinks) {
|
|
|
38865
38880
|
return mergeWithDefaults(mergeWithDefaults(_ssrConfigDefaults, { optimizeDeps: { esbuildOptions: { preserveSymlinks } } }), ssr ?? {});
|
|
38866
38881
|
}
|
|
38867
38882
|
//#endregion
|
|
38868
|
-
//#region ../../
|
|
38883
|
+
//#region ../../vite/packages/vite/src/node/ssr/runnerImport.ts
|
|
38869
38884
|
/**
|
|
38870
38885
|
* Import any file using the default Vite environment.
|
|
38871
38886
|
* @experimental
|
|
@@ -38904,7 +38919,7 @@ async function runnerImport(moduleId, inlineConfig) {
|
|
|
38904
38919
|
}
|
|
38905
38920
|
}
|
|
38906
38921
|
//#endregion
|
|
38907
|
-
//#region ../../
|
|
38922
|
+
//#region ../../vite/packages/vite/src/node/optimizer/pluginConverter.ts
|
|
38908
38923
|
function convertEsbuildPluginToRolldownPlugin(esbuildPlugin) {
|
|
38909
38924
|
const onStartCallbacks = [];
|
|
38910
38925
|
const onEndCallbacks = [];
|
|
@@ -39055,7 +39070,7 @@ function idToPathAndNamespace(id) {
|
|
|
39055
39070
|
else return [id, "file"];
|
|
39056
39071
|
}
|
|
39057
39072
|
//#endregion
|
|
39058
|
-
//#region ../../
|
|
39073
|
+
//#region ../../vite/packages/vite/src/node/config.ts
|
|
39059
39074
|
const debug = createDebugger("vite:config", { depth: 10 });
|
|
39060
39075
|
const promisifiedRealpath = promisify(fs.realpath);
|
|
39061
39076
|
const SYMBOL_RESOLVED_CONFIG = Symbol("vite:resolved-config");
|
|
@@ -39960,7 +39975,7 @@ function optimizeDepsDisabledBackwardCompatibility(resolved, optimizeDeps, optim
|
|
|
39960
39975
|
}
|
|
39961
39976
|
}
|
|
39962
39977
|
//#endregion
|
|
39963
|
-
//#region ../../
|
|
39978
|
+
//#region ../../vite/packages/vite/src/node/server/environments/fetchableEnvironments.ts
|
|
39964
39979
|
function createFetchableDevEnvironment(name, config, context) {
|
|
39965
39980
|
if (typeof Request === "undefined" || typeof Response === "undefined") throw new TypeError("FetchableDevEnvironment requires a global `Request` and `Response` object.");
|
|
39966
39981
|
if (!context.handleRequest) throw new TypeError("FetchableDevEnvironment requires a `handleRequest` method during initialisation.");
|
|
@@ -39983,7 +39998,7 @@ var FetchableDevEnvironment = class extends DevEnvironment {
|
|
|
39983
39998
|
}
|
|
39984
39999
|
};
|
|
39985
40000
|
//#endregion
|
|
39986
|
-
//#region ../../
|
|
40001
|
+
//#region ../../vite/packages/vite/src/node/index.ts
|
|
39987
40002
|
/** @deprecated - use `parse` instead */
|
|
39988
40003
|
const parseAst$1 = parseAst;
|
|
39989
40004
|
/** @deprecated - use `parseAsync` instead */
|