@cloudflare/vite-plugin 1.29.1 → 1.30.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/dist/index.mjs +4158 -545
- package/dist/index.mjs.map +1 -1
- package/dist/{package-JK3bcV9H.mjs → package-BOguDXuZ.mjs} +13 -14
- package/dist/package-BOguDXuZ.mjs.map +1 -0
- package/dist/workers/runner-worker/module-runner-legacy.js +1 -1
- package/dist/workers/runner-worker/module-runner.js +2 -2
- package/package.json +20 -21
- package/dist/package-JK3bcV9H.mjs.map +0 -1
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
//#region package.json
|
|
2
2
|
var package_default = {
|
|
3
3
|
name: "@cloudflare/vite-plugin",
|
|
4
|
-
version: "1.
|
|
4
|
+
version: "1.30.1",
|
|
5
5
|
description: "Cloudflare plugin for Vite",
|
|
6
6
|
keywords: [
|
|
7
7
|
"cloudflare",
|
|
8
|
-
"workers",
|
|
9
8
|
"cloudflare-workers",
|
|
10
9
|
"vite",
|
|
11
|
-
"vite-plugin"
|
|
10
|
+
"vite-plugin",
|
|
11
|
+
"workers"
|
|
12
12
|
],
|
|
13
13
|
homepage: "https://github.com/cloudflare/workers-sdk/tree/main/packages/vite-plugin-cloudflare#readme",
|
|
14
14
|
bugs: { "url": "https://github.com/cloudflare/workers-sdk/issues" },
|
|
15
|
+
license: "MIT",
|
|
15
16
|
repository: {
|
|
16
17
|
"type": "git",
|
|
17
18
|
"url": "https://github.com/cloudflare/workers-sdk.git",
|
|
18
19
|
"directory": "packages/vite-plugin-cloudflare"
|
|
19
20
|
},
|
|
20
|
-
|
|
21
|
-
sideEffects: false,
|
|
21
|
+
files: ["dist"],
|
|
22
22
|
type: "module",
|
|
23
|
+
sideEffects: false,
|
|
24
|
+
main: "./dist/index.mjs",
|
|
25
|
+
types: "./dist/index.d.mts",
|
|
23
26
|
exports: { ".": {
|
|
24
27
|
"types": "./dist/index.d.mts",
|
|
25
28
|
"import": "./dist/index.mjs"
|
|
26
29
|
} },
|
|
27
|
-
|
|
28
|
-
types: "./dist/index.d.mts",
|
|
29
|
-
files: ["dist"],
|
|
30
|
+
publishConfig: { "access": "public" },
|
|
30
31
|
scripts: {
|
|
31
32
|
"build": "tsdown",
|
|
32
|
-
"check:lint": "eslint . --max-warnings=0 --cache",
|
|
33
33
|
"check:type": "tsc --build",
|
|
34
34
|
"dev": "tsdown --watch",
|
|
35
35
|
"test": "vitest run",
|
|
@@ -52,7 +52,7 @@ var package_default = {
|
|
|
52
52
|
"@cloudflare/workers-types": "catalog:default",
|
|
53
53
|
"@cloudflare/workers-utils": "workspace:*",
|
|
54
54
|
"@remix-run/node-fetch-server": "^0.8.0",
|
|
55
|
-
"@types/node": "catalog:
|
|
55
|
+
"@types/node": "catalog:default",
|
|
56
56
|
"@types/semver": "^7.5.1",
|
|
57
57
|
"@types/ws": "^8.5.13",
|
|
58
58
|
"defu": "^6.1.4",
|
|
@@ -65,18 +65,17 @@ var package_default = {
|
|
|
65
65
|
"tree-kill": "catalog:default",
|
|
66
66
|
"tsdown": "0.16.3",
|
|
67
67
|
"typescript": "catalog:default",
|
|
68
|
-
"vite": "catalog:
|
|
68
|
+
"vite": "catalog:default",
|
|
69
69
|
"vite-legacy": "npm:vite@7.1.12",
|
|
70
|
-
"vitest": "catalog:
|
|
70
|
+
"vitest": "catalog:default"
|
|
71
71
|
},
|
|
72
72
|
peerDependencies: {
|
|
73
73
|
"vite": "^6.1.0 || ^7.0.0 || ^8.0.0",
|
|
74
74
|
"wrangler": "workspace:^"
|
|
75
75
|
},
|
|
76
|
-
publishConfig: { "access": "public" },
|
|
77
76
|
"workers-sdk": { "prerelease": true }
|
|
78
77
|
};
|
|
79
78
|
|
|
80
79
|
//#endregion
|
|
81
80
|
export { package_default as default };
|
|
82
|
-
//# sourceMappingURL=package-
|
|
81
|
+
//# sourceMappingURL=package-BOguDXuZ.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"package-BOguDXuZ.mjs","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@cloudflare/vite-plugin\",\n\t\"version\": \"1.30.1\",\n\t\"description\": \"Cloudflare plugin for Vite\",\n\t\"keywords\": [\n\t\t\"cloudflare\",\n\t\t\"cloudflare-workers\",\n\t\t\"vite\",\n\t\t\"vite-plugin\",\n\t\t\"workers\"\n\t],\n\t\"homepage\": \"https://github.com/cloudflare/workers-sdk/tree/main/packages/vite-plugin-cloudflare#readme\",\n\t\"bugs\": {\n\t\t\"url\": \"https://github.com/cloudflare/workers-sdk/issues\"\n\t},\n\t\"license\": \"MIT\",\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"https://github.com/cloudflare/workers-sdk.git\",\n\t\t\"directory\": \"packages/vite-plugin-cloudflare\"\n\t},\n\t\"files\": [\n\t\t\"dist\"\n\t],\n\t\"type\": \"module\",\n\t\"sideEffects\": false,\n\t\"main\": \"./dist/index.mjs\",\n\t\"types\": \"./dist/index.d.mts\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"types\": \"./dist/index.d.mts\",\n\t\t\t\"import\": \"./dist/index.mjs\"\n\t\t}\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t},\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"check:type\": \"tsc --build\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"test\": \"vitest run\",\n\t\t\"test:ci\": \"pnpm test\",\n\t\t\"test:e2e\": \"vitest run -c e2e/vitest.config.ts\",\n\t\t\"test:watch\": \"vitest\"\n\t},\n\t\"dependencies\": {\n\t\t\"@cloudflare/unenv-preset\": \"workspace:*\",\n\t\t\"miniflare\": \"workspace:*\",\n\t\t\"unenv\": \"2.0.0-rc.24\",\n\t\t\"wrangler\": \"workspace:*\",\n\t\t\"ws\": \"catalog:default\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@cloudflare/containers-shared\": \"workspace:*\",\n\t\t\"@cloudflare/mock-npm-registry\": \"workspace:*\",\n\t\t\"@cloudflare/workers-shared\": \"workspace:*\",\n\t\t\"@cloudflare/workers-tsconfig\": \"workspace:*\",\n\t\t\"@cloudflare/workers-types\": \"catalog:default\",\n\t\t\"@cloudflare/workers-utils\": \"workspace:*\",\n\t\t\"@remix-run/node-fetch-server\": \"^0.8.0\",\n\t\t\"@types/node\": \"catalog:default\",\n\t\t\"@types/semver\": \"^7.5.1\",\n\t\t\"@types/ws\": \"^8.5.13\",\n\t\t\"defu\": \"^6.1.4\",\n\t\t\"get-port\": \"^7.1.0\",\n\t\t\"magic-string\": \"^0.30.12\",\n\t\t\"mlly\": \"^1.7.4\",\n\t\t\"picocolors\": \"^1.1.1\",\n\t\t\"semver\": \"^7.7.1\",\n\t\t\"tinyglobby\": \"^0.2.12\",\n\t\t\"tree-kill\": \"catalog:default\",\n\t\t\"tsdown\": \"0.16.3\",\n\t\t\"typescript\": \"catalog:default\",\n\t\t\"vite\": \"catalog:default\",\n\t\t\"vite-legacy\": \"npm:vite@7.1.12\",\n\t\t\"vitest\": \"catalog:default\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"vite\": \"^6.1.0 || ^7.0.0 || ^8.0.0\",\n\t\t\"wrangler\": \"workspace:^\"\n\t},\n\t\"workers-sdk\": {\n\t\t\"prerelease\": true\n\t}\n}\n"],"mappings":";sBAAA;OACS;UACG;cACI;WACH;EACX;EACA;EACA;EACA;EACA;EACA;WACW;OACJ,EACP,OAAO,oDACP;UACU;aACG;EACb,QAAQ;EACR,OAAO;EACP,aAAa;EACb;QACQ,CACR,OACA;OACO;cACO;OACP;QACC;UACE,EACV,KAAK;EACJ,SAAS;EACT,UAAU;EACV,EACD;gBACgB,EAChB,UAAU,UACV;UACU;EACV,SAAS;EACT,cAAc;EACd,OAAO;EACP,QAAQ;EACR,WAAW;EACX,YAAY;EACZ,cAAc;EACd;eACe;EACf,4BAA4B;EAC5B,aAAa;EACb,SAAS;EACT,YAAY;EACZ,MAAM;EACN;kBACkB;EAClB,iCAAiC;EACjC,iCAAiC;EACjC,8BAA8B;EAC9B,gCAAgC;EAChC,6BAA6B;EAC7B,6BAA6B;EAC7B,gCAAgC;EAChC,eAAe;EACf,iBAAiB;EACjB,aAAa;EACb,QAAQ;EACR,YAAY;EACZ,gBAAgB;EAChB,QAAQ;EACR,cAAc;EACd,UAAU;EACV,cAAc;EACd,aAAa;EACb,UAAU;EACV,cAAc;EACd,QAAQ;EACR,eAAe;EACf,UAAU;EACV;mBACmB;EACnB,QAAQ;EACR,YAAY;EACZ;CACD,eAAe,EACd,cAAc,MACd;CACD"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/vite@7.1.12_@types+node@
|
|
1
|
+
//#region ../../node_modules/.pnpm/vite@7.1.12_@types+node@22.15.17_jiti@2.6.1_lightningcss@1.32.0_tsx@4.21.0_yaml@2.8.1/node_modules/vite/dist/node/module-runner.js
|
|
2
2
|
let SOURCEMAPPING_URL = "sourceMa";
|
|
3
3
|
SOURCEMAPPING_URL += "ppingURL";
|
|
4
4
|
const isWindows = typeof process < "u" && process.platform === "win32";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
//#region ../../node_modules/.pnpm/vite@8.0.
|
|
1
|
+
//#region ../../node_modules/.pnpm/vite@8.0.1_@types+node@22.15.17_esbuild@0.27.3_jiti@2.6.1_tsx@4.21.0_yaml@2.8.1/node_modules/vite/dist/node/module-runner.js
|
|
2
2
|
let SOURCEMAPPING_URL = "sourceMa";
|
|
3
3
|
SOURCEMAPPING_URL += "ppingURL";
|
|
4
4
|
const isWindows = typeof process < "u" && process.platform === "win32";
|
|
@@ -500,7 +500,7 @@ function analyzeImportedModDifference(mod, rawId, moduleType, metadata) {
|
|
|
500
500
|
let missingBindings = metadata.importedNames.filter((s) => !(s in mod));
|
|
501
501
|
if (missingBindings.length) {
|
|
502
502
|
let lastBinding = missingBindings[missingBindings.length - 1];
|
|
503
|
-
throw moduleType === "module" ?
|
|
503
|
+
throw SyntaxError(moduleType === "module" ? `[vite] The requested module '${rawId}' does not provide an export named '${lastBinding}'` : `\
|
|
504
504
|
[vite] Named export '${lastBinding}' not found. The requested module '${rawId}' is a CommonJS module, which may not support all module.exports as named exports.
|
|
505
505
|
CommonJS modules can always be imported via the default export, for example using:
|
|
506
506
|
|
package/package.json
CHANGED
|
@@ -1,43 +1,46 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cloudflare/vite-plugin",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.30.1",
|
|
4
4
|
"description": "Cloudflare plugin for Vite",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"cloudflare",
|
|
7
|
-
"workers",
|
|
8
7
|
"cloudflare-workers",
|
|
9
8
|
"vite",
|
|
10
|
-
"vite-plugin"
|
|
9
|
+
"vite-plugin",
|
|
10
|
+
"workers"
|
|
11
11
|
],
|
|
12
12
|
"homepage": "https://github.com/cloudflare/workers-sdk/tree/main/packages/vite-plugin-cloudflare#readme",
|
|
13
13
|
"bugs": {
|
|
14
14
|
"url": "https://github.com/cloudflare/workers-sdk/issues"
|
|
15
15
|
},
|
|
16
|
+
"license": "MIT",
|
|
16
17
|
"repository": {
|
|
17
18
|
"type": "git",
|
|
18
19
|
"url": "https://github.com/cloudflare/workers-sdk.git",
|
|
19
20
|
"directory": "packages/vite-plugin-cloudflare"
|
|
20
21
|
},
|
|
21
|
-
"
|
|
22
|
-
|
|
22
|
+
"files": [
|
|
23
|
+
"dist"
|
|
24
|
+
],
|
|
23
25
|
"type": "module",
|
|
26
|
+
"sideEffects": false,
|
|
27
|
+
"main": "./dist/index.mjs",
|
|
28
|
+
"types": "./dist/index.d.mts",
|
|
24
29
|
"exports": {
|
|
25
30
|
".": {
|
|
26
31
|
"types": "./dist/index.d.mts",
|
|
27
32
|
"import": "./dist/index.mjs"
|
|
28
33
|
}
|
|
29
34
|
},
|
|
30
|
-
"
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
"dist"
|
|
34
|
-
],
|
|
35
|
+
"publishConfig": {
|
|
36
|
+
"access": "public"
|
|
37
|
+
},
|
|
35
38
|
"dependencies": {
|
|
36
39
|
"unenv": "2.0.0-rc.24",
|
|
37
40
|
"ws": "8.18.0",
|
|
38
|
-
"@cloudflare/unenv-preset": "2.
|
|
39
|
-
"miniflare": "4.20260317.
|
|
40
|
-
"wrangler": "4.
|
|
41
|
+
"@cloudflare/unenv-preset": "2.16.0",
|
|
42
|
+
"miniflare": "4.20260317.2",
|
|
43
|
+
"wrangler": "4.77.0"
|
|
41
44
|
},
|
|
42
45
|
"devDependencies": {
|
|
43
46
|
"@cloudflare/workers-types": "^4.20260317.1",
|
|
@@ -57,26 +60,22 @@
|
|
|
57
60
|
"typescript": "~5.8.3",
|
|
58
61
|
"vite": "^8.0.0",
|
|
59
62
|
"vite-legacy": "npm:vite@7.1.12",
|
|
60
|
-
"vitest": "
|
|
61
|
-
"@cloudflare/containers-shared": "0.
|
|
63
|
+
"vitest": "4.1.0",
|
|
64
|
+
"@cloudflare/containers-shared": "0.13.0",
|
|
62
65
|
"@cloudflare/mock-npm-registry": "0.0.0",
|
|
63
66
|
"@cloudflare/workers-shared": "0.19.1",
|
|
64
67
|
"@cloudflare/workers-tsconfig": "0.0.0",
|
|
65
|
-
"@cloudflare/workers-utils": "0.
|
|
68
|
+
"@cloudflare/workers-utils": "0.13.0"
|
|
66
69
|
},
|
|
67
70
|
"peerDependencies": {
|
|
68
71
|
"vite": "^6.1.0 || ^7.0.0 || ^8.0.0",
|
|
69
|
-
"wrangler": "^4.
|
|
70
|
-
},
|
|
71
|
-
"publishConfig": {
|
|
72
|
-
"access": "public"
|
|
72
|
+
"wrangler": "^4.77.0"
|
|
73
73
|
},
|
|
74
74
|
"workers-sdk": {
|
|
75
75
|
"prerelease": true
|
|
76
76
|
},
|
|
77
77
|
"scripts": {
|
|
78
78
|
"build": "tsdown",
|
|
79
|
-
"check:lint": "eslint . --max-warnings=0 --cache",
|
|
80
79
|
"check:type": "tsc --build",
|
|
81
80
|
"dev": "tsdown --watch",
|
|
82
81
|
"test": "vitest run",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"package-JK3bcV9H.mjs","names":[],"sources":["../package.json"],"sourcesContent":["{\n\t\"name\": \"@cloudflare/vite-plugin\",\n\t\"version\": \"1.29.1\",\n\t\"description\": \"Cloudflare plugin for Vite\",\n\t\"keywords\": [\n\t\t\"cloudflare\",\n\t\t\"workers\",\n\t\t\"cloudflare-workers\",\n\t\t\"vite\",\n\t\t\"vite-plugin\"\n\t],\n\t\"homepage\": \"https://github.com/cloudflare/workers-sdk/tree/main/packages/vite-plugin-cloudflare#readme\",\n\t\"bugs\": {\n\t\t\"url\": \"https://github.com/cloudflare/workers-sdk/issues\"\n\t},\n\t\"repository\": {\n\t\t\"type\": \"git\",\n\t\t\"url\": \"https://github.com/cloudflare/workers-sdk.git\",\n\t\t\"directory\": \"packages/vite-plugin-cloudflare\"\n\t},\n\t\"license\": \"MIT\",\n\t\"sideEffects\": false,\n\t\"type\": \"module\",\n\t\"exports\": {\n\t\t\".\": {\n\t\t\t\"types\": \"./dist/index.d.mts\",\n\t\t\t\"import\": \"./dist/index.mjs\"\n\t\t}\n\t},\n\t\"main\": \"./dist/index.mjs\",\n\t\"types\": \"./dist/index.d.mts\",\n\t\"files\": [\n\t\t\"dist\"\n\t],\n\t\"scripts\": {\n\t\t\"build\": \"tsdown\",\n\t\t\"check:lint\": \"eslint . --max-warnings=0 --cache\",\n\t\t\"check:type\": \"tsc --build\",\n\t\t\"dev\": \"tsdown --watch\",\n\t\t\"test\": \"vitest run\",\n\t\t\"test:ci\": \"pnpm test\",\n\t\t\"test:e2e\": \"vitest run -c e2e/vitest.config.ts\",\n\t\t\"test:watch\": \"vitest\"\n\t},\n\t\"dependencies\": {\n\t\t\"@cloudflare/unenv-preset\": \"workspace:*\",\n\t\t\"miniflare\": \"workspace:*\",\n\t\t\"unenv\": \"2.0.0-rc.24\",\n\t\t\"wrangler\": \"workspace:*\",\n\t\t\"ws\": \"catalog:default\"\n\t},\n\t\"devDependencies\": {\n\t\t\"@cloudflare/containers-shared\": \"workspace:*\",\n\t\t\"@cloudflare/mock-npm-registry\": \"workspace:*\",\n\t\t\"@cloudflare/workers-shared\": \"workspace:*\",\n\t\t\"@cloudflare/workers-tsconfig\": \"workspace:*\",\n\t\t\"@cloudflare/workers-types\": \"catalog:default\",\n\t\t\"@cloudflare/workers-utils\": \"workspace:*\",\n\t\t\"@remix-run/node-fetch-server\": \"^0.8.0\",\n\t\t\"@types/node\": \"catalog:vite-plugin\",\n\t\t\"@types/semver\": \"^7.5.1\",\n\t\t\"@types/ws\": \"^8.5.13\",\n\t\t\"defu\": \"^6.1.4\",\n\t\t\"get-port\": \"^7.1.0\",\n\t\t\"magic-string\": \"^0.30.12\",\n\t\t\"mlly\": \"^1.7.4\",\n\t\t\"picocolors\": \"^1.1.1\",\n\t\t\"semver\": \"^7.7.1\",\n\t\t\"tinyglobby\": \"^0.2.12\",\n\t\t\"tree-kill\": \"catalog:default\",\n\t\t\"tsdown\": \"0.16.3\",\n\t\t\"typescript\": \"catalog:default\",\n\t\t\"vite\": \"catalog:vite-plugin\",\n\t\t\"vite-legacy\": \"npm:vite@7.1.12\",\n\t\t\"vitest\": \"catalog:vitest-3\"\n\t},\n\t\"peerDependencies\": {\n\t\t\"vite\": \"^6.1.0 || ^7.0.0 || ^8.0.0\",\n\t\t\"wrangler\": \"workspace:^\"\n\t},\n\t\"publishConfig\": {\n\t\t\"access\": \"public\"\n\t},\n\t\"workers-sdk\": {\n\t\t\"prerelease\": true\n\t}\n}\n"],"mappings":";sBAAA;OACS;UACG;cACI;WACH;EACX;EACA;EACA;EACA;EACA;EACA;WACW;OACJ,EACP,OAAO,oDACP;aACa;EACb,QAAQ;EACR,OAAO;EACP,aAAa;EACb;UACU;cACI;OACP;UACG,EACV,KAAK;EACJ,SAAS;EACT,UAAU;EACV,EACD;OACO;QACC;QACA,CACR,OACA;UACU;EACV,SAAS;EACT,cAAc;EACd,cAAc;EACd,OAAO;EACP,QAAQ;EACR,WAAW;EACX,YAAY;EACZ,cAAc;EACd;eACe;EACf,4BAA4B;EAC5B,aAAa;EACb,SAAS;EACT,YAAY;EACZ,MAAM;EACN;kBACkB;EAClB,iCAAiC;EACjC,iCAAiC;EACjC,8BAA8B;EAC9B,gCAAgC;EAChC,6BAA6B;EAC7B,6BAA6B;EAC7B,gCAAgC;EAChC,eAAe;EACf,iBAAiB;EACjB,aAAa;EACb,QAAQ;EACR,YAAY;EACZ,gBAAgB;EAChB,QAAQ;EACR,cAAc;EACd,UAAU;EACV,cAAc;EACd,aAAa;EACb,UAAU;EACV,cAAc;EACd,QAAQ;EACR,eAAe;EACf,UAAU;EACV;mBACmB;EACnB,QAAQ;EACR,YAAY;EACZ;gBACgB,EAChB,UAAU,UACV;CACD,eAAe,EACd,cAAc,MACd;CACD"}
|