vite 7.0.0-beta.0 → 7.0.0-beta.1
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/bin/vite.js +4 -4
- package/dist/client/client.mjs +14 -14
- package/dist/node/chunks/{dep-Ccq9jQdz.js → dep-3PhSlasG.js} +1 -1
- package/dist/node/chunks/{dep-RiwDEHuV.js → dep-BO5GbxpL.js} +3 -3
- package/dist/node/chunks/{dep-D_UgUiRQ.js → dep-BaSfMtGz.js} +1 -1
- package/dist/node/chunks/{dep-P8c3Tybu.js → dep-Bb92EWrU.js} +1 -1
- package/dist/node/chunks/{dep-3jlWaCfC.js → dep-C9KS6hrN.js} +1 -1
- package/dist/node/chunks/{dep-bvBD1i2C.js → dep-Da5Rc_CS.js} +656 -625
- package/dist/node/chunks/{dep-CCzsqxOh.js → dep-Dg4W3IAQ.js} +49 -49
- package/dist/node/chunks/{dep-FHYvcJhE.js → dep-uSUFJk9A.js} +20 -20
- package/dist/node/cli.js +6 -6
- package/dist/node/index.d.ts +9 -58
- package/dist/node/index.js +1 -1
- package/dist/node/module-runner.d.ts +9 -12
- package/dist/node/module-runner.js +27 -22
- package/dist/node/{moduleRunnerTransport-CnL9s_k9.d.ts → moduleRunnerTransport-BWUZBVLX.d.ts} +2 -2
- package/package.json +8 -9
- package/types/importGlob.d.ts +4 -0
- package/types/internal/cssPreprocessorOptions.d.ts +3 -3
package/bin/vite.js
CHANGED
@@ -3,10 +3,10 @@ import { performance } from 'node:perf_hooks'
|
|
3
3
|
import module from 'node:module'
|
4
4
|
|
5
5
|
if (!import.meta.url.includes('node_modules')) {
|
6
|
-
|
7
|
-
// only
|
8
|
-
|
9
|
-
}
|
6
|
+
if (!process.env.DEBUG_DISABLE_SOURCE_MAP) {
|
7
|
+
// eslint-disable-next-line n/no-unsupported-features/node-builtins -- only used in dev
|
8
|
+
process.setSourceMapsEnabled(true)
|
9
|
+
}
|
10
10
|
|
11
11
|
process.on('unhandledRejection', (err) => {
|
12
12
|
throw new Error('UNHANDLED PROMISE REJECTION', { cause: err })
|
package/dist/client/client.mjs
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import "@vite/env";
|
2
2
|
|
3
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
3
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.72.1/node_modules/@oxc-project/runtime/src/helpers/esm/typeof.js
|
4
4
|
function _typeof(o) {
|
5
5
|
"@babel/helpers - typeof";
|
6
6
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o$1) {
|
@@ -11,7 +11,7 @@ function _typeof(o) {
|
|
11
11
|
}
|
12
12
|
|
13
13
|
//#endregion
|
14
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
14
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.72.1/node_modules/@oxc-project/runtime/src/helpers/esm/toPrimitive.js
|
15
15
|
function toPrimitive(t, r) {
|
16
16
|
if ("object" != _typeof(t) || !t) return t;
|
17
17
|
var e = t[Symbol.toPrimitive];
|
@@ -24,14 +24,14 @@ function toPrimitive(t, r) {
|
|
24
24
|
}
|
25
25
|
|
26
26
|
//#endregion
|
27
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
27
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.72.1/node_modules/@oxc-project/runtime/src/helpers/esm/toPropertyKey.js
|
28
28
|
function toPropertyKey(t) {
|
29
29
|
var i = toPrimitive(t, "string");
|
30
30
|
return "symbol" == _typeof(i) ? i : i + "";
|
31
31
|
}
|
32
32
|
|
33
33
|
//#endregion
|
34
|
-
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.
|
34
|
+
//#region ../../node_modules/.pnpm/@oxc-project+runtime@0.72.1/node_modules/@oxc-project/runtime/src/helpers/esm/defineProperty.js
|
35
35
|
function _defineProperty(e, r, t) {
|
36
36
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
37
37
|
value: t,
|
@@ -56,7 +56,7 @@ var HMRContext = class {
|
|
56
56
|
const listeners = hmrClient$1.customListenersMap.get(event);
|
57
57
|
if (listeners) hmrClient$1.customListenersMap.set(event, listeners.filter((l) => !staleFns.includes(l)));
|
58
58
|
}
|
59
|
-
this.newListeners = new Map();
|
59
|
+
this.newListeners = /* @__PURE__ */ new Map();
|
60
60
|
hmrClient$1.ctxToListenersMap.set(ownerPath, this.newListeners);
|
61
61
|
}
|
62
62
|
get data() {
|
@@ -139,12 +139,12 @@ var HMRClient = class {
|
|
139
139
|
this.logger = logger;
|
140
140
|
this.transport = transport$1;
|
141
141
|
this.importUpdatedModule = importUpdatedModule;
|
142
|
-
_defineProperty(this, "hotModulesMap", new Map());
|
143
|
-
_defineProperty(this, "disposeMap", new Map());
|
144
|
-
_defineProperty(this, "pruneMap", new Map());
|
145
|
-
_defineProperty(this, "dataMap", new Map());
|
146
|
-
_defineProperty(this, "customListenersMap", new Map());
|
147
|
-
_defineProperty(this, "ctxToListenersMap", new Map());
|
142
|
+
_defineProperty(this, "hotModulesMap", /* @__PURE__ */ new Map());
|
143
|
+
_defineProperty(this, "disposeMap", /* @__PURE__ */ new Map());
|
144
|
+
_defineProperty(this, "pruneMap", /* @__PURE__ */ new Map());
|
145
|
+
_defineProperty(this, "dataMap", /* @__PURE__ */ new Map());
|
146
|
+
_defineProperty(this, "customListenersMap", /* @__PURE__ */ new Map());
|
147
|
+
_defineProperty(this, "ctxToListenersMap", /* @__PURE__ */ new Map());
|
148
148
|
_defineProperty(this, "currentFirstInvalidatedBy", void 0);
|
149
149
|
_defineProperty(this, "updateQueue", []);
|
150
150
|
_defineProperty(this, "pendingUpdateQueue", false);
|
@@ -283,7 +283,7 @@ const createInvokeableTransport = (transport$1) => {
|
|
283
283
|
}
|
284
284
|
};
|
285
285
|
if (!transport$1.send || !transport$1.connect) throw new Error("transport must implement send and connect when invoke is not implemented");
|
286
|
-
const rpcPromises = new Map();
|
286
|
+
const rpcPromises = /* @__PURE__ */ new Map();
|
287
287
|
return {
|
288
288
|
...transport$1,
|
289
289
|
connect({ onMessage, onDisconnection }) {
|
@@ -791,7 +791,7 @@ function cleanUrl(pathname) {
|
|
791
791
|
return url.pathname + url.search;
|
792
792
|
}
|
793
793
|
let isFirstUpdate = true;
|
794
|
-
const outdatedLinkTags = new WeakSet();
|
794
|
+
const outdatedLinkTags = /* @__PURE__ */ new WeakSet();
|
795
795
|
const debounceReload = (time) => {
|
796
796
|
let timer;
|
797
797
|
return () => {
|
@@ -958,7 +958,7 @@ function waitForWindowShow() {
|
|
958
958
|
document.addEventListener("visibilitychange", onChange);
|
959
959
|
});
|
960
960
|
}
|
961
|
-
const sheetsMap = new Map();
|
961
|
+
const sheetsMap = /* @__PURE__ */ new Map();
|
962
962
|
if ("document" in globalThis) document.querySelectorAll("style[data-vite-dev-id]").forEach((el) => {
|
963
963
|
sheetsMap.set(el.getAttribute("data-vite-dev-id"), el);
|
964
964
|
});
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { createRequire as ___createRequire } from 'module'; const require = ___createRequire(import.meta.url);
|
2
|
-
import { BuildEnvironment, build, buildEnvironmentOptionsDefaults, builderOptionsDefaults, createBuilder, createToImportMetaURLBasedRelativeRuntime, injectEnvironmentToHooks, onRollupLog, resolveBuildEnvironmentOptions, resolveBuildOutputs, resolveBuildPlugins, resolveBuilderOptions, resolveLibFilename, resolveUserExternal, toOutputFilePathInCss, toOutputFilePathInHtml, toOutputFilePathInJS, toOutputFilePathWithoutRuntime } from "./dep-
|
2
|
+
import { BuildEnvironment, build, buildEnvironmentOptionsDefaults, builderOptionsDefaults, createBuilder, createToImportMetaURLBasedRelativeRuntime, injectEnvironmentToHooks, onRollupLog, resolveBuildEnvironmentOptions, resolveBuildOutputs, resolveBuildPlugins, resolveBuilderOptions, resolveLibFilename, resolveUserExternal, toOutputFilePathInCss, toOutputFilePathInHtml, toOutputFilePathInJS, toOutputFilePathWithoutRuntime } from "./dep-Da5Rc_CS.js";
|
3
3
|
import "./dep-Ctugieod.js";
|
4
4
|
|
5
5
|
export { createBuilder, resolveBuildPlugins };
|
@@ -1241,9 +1241,9 @@ const SPECIAL_ELEMENTS = {
|
|
1241
1241
|
$.FOREIGN_OBJECT,
|
1242
1242
|
$.DESC
|
1243
1243
|
]),
|
1244
|
-
[NS.XLINK]: new Set(),
|
1245
|
-
[NS.XML]: new Set(),
|
1246
|
-
[NS.XMLNS]: new Set()
|
1244
|
+
[NS.XLINK]: /* @__PURE__ */ new Set(),
|
1245
|
+
[NS.XML]: /* @__PURE__ */ new Set(),
|
1246
|
+
[NS.XMLNS]: /* @__PURE__ */ new Set()
|
1247
1247
|
};
|
1248
1248
|
const NUMBERED_HEADERS = new Set([
|
1249
1249
|
$.H1,
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { createRequire as ___createRequire } from 'module'; const require = ___createRequire(import.meta.url);
|
2
|
-
import { _createServer, createServer, createServerCloseFn, resolveServerOptions, restartServerWithUrls, serverConfigDefaults } from "./dep-
|
2
|
+
import { _createServer, createServer, createServerCloseFn, resolveServerOptions, restartServerWithUrls, serverConfigDefaults } from "./dep-Da5Rc_CS.js";
|
3
3
|
import "./dep-Ctugieod.js";
|
4
4
|
|
5
5
|
export { createServer };
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { createRequire as ___createRequire } from 'module'; const require = ___createRequire(import.meta.url);
|
2
|
-
import { addManuallyIncludedOptimizeDeps, addOptimizedDepInfo, cleanupDepsCacheStaleDirs, createIsOptimizedDepFile, createIsOptimizedDepUrl, depsFromOptimizedDepInfo, depsLogString, discoverProjectDependencies, extractExportsData, getDepsCacheDir, getOptimizedDepPath, initDepsOptimizerMetadata, isDepOptimizationDisabled, loadCachedDepOptimizationMetadata, optimizeDeps, optimizeExplicitEnvironmentDeps, optimizedDepInfoFromFile, optimizedDepInfoFromId, optimizedDepNeedsInterop, runOptimizeDeps, toDiscoveredDependencies } from "./dep-
|
2
|
+
import { addManuallyIncludedOptimizeDeps, addOptimizedDepInfo, cleanupDepsCacheStaleDirs, createIsOptimizedDepFile, createIsOptimizedDepUrl, depsFromOptimizedDepInfo, depsLogString, discoverProjectDependencies, extractExportsData, getDepsCacheDir, getOptimizedDepPath, initDepsOptimizerMetadata, isDepOptimizationDisabled, loadCachedDepOptimizationMetadata, optimizeDeps, optimizeExplicitEnvironmentDeps, optimizedDepInfoFromFile, optimizedDepInfoFromId, optimizedDepNeedsInterop, runOptimizeDeps, toDiscoveredDependencies } from "./dep-Da5Rc_CS.js";
|
3
3
|
import "./dep-Ctugieod.js";
|
4
4
|
|
5
5
|
export { optimizeDeps };
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { createRequire as ___createRequire } from 'module'; const require = ___createRequire(import.meta.url);
|
2
|
-
import { preview, resolvePreviewOptions } from "./dep-
|
2
|
+
import { preview, resolvePreviewOptions } from "./dep-Da5Rc_CS.js";
|
3
3
|
import "./dep-Ctugieod.js";
|
4
4
|
|
5
5
|
export { preview };
|