@voidzero-dev/vite-plus-core 0.2.8 → 0.3.0

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.
Files changed (63) hide show
  1. package/LICENSE +30 -1
  2. package/dist/rolldown/cli.mjs +14 -10
  3. package/dist/rolldown/config.d.mts +1 -1
  4. package/dist/rolldown/config.mjs +2 -2
  5. package/dist/rolldown/experimental-index.d.mts +5 -5
  6. package/dist/rolldown/experimental-index.mjs +11 -9
  7. package/dist/rolldown/filter-index.d.mts +1 -1
  8. package/dist/rolldown/index.d.mts +2 -2
  9. package/dist/rolldown/index.mjs +4 -4
  10. package/dist/rolldown/parallel-plugin-worker.mjs +2 -2
  11. package/dist/rolldown/parallel-plugin.d.mts +1 -1
  12. package/dist/rolldown/parse-ast-index.d.mts +1 -1
  13. package/dist/rolldown/parse-ast-index.mjs +1 -1
  14. package/dist/rolldown/plugins-index.d.mts +3 -3
  15. package/dist/rolldown/plugins-index.mjs +2 -2
  16. package/dist/rolldown/shared/{binding-CVtkJvyl.d.mts → binding-Bvw14S3g.d.mts} +70 -1
  17. package/dist/rolldown/shared/binding-C__LJDBG.mjs +675 -0
  18. package/dist/rolldown/shared/{bindingify-input-options-B03y7DfJ.mjs → bindingify-input-options-V9YvAjrr.mjs} +6 -10
  19. package/dist/rolldown/shared/{constructors-ALilxAii.d.mts → constructors-CRumnw21.d.mts} +2 -2
  20. package/dist/rolldown/shared/{constructors-COwFYQna.mjs → constructors-DklcHr18.mjs} +1 -1
  21. package/dist/rolldown/shared/{create-bundler-option-B-tSTZRt.mjs → create-bundler-option-DbV2ud0B.mjs} +5 -4
  22. package/dist/rolldown/shared/{define-config-DSMNXceb.d.mts → define-config-DwTNhgWB.d.mts} +12 -10
  23. package/dist/rolldown/shared/{error-nLggAzpQ.mjs → error-NcRuXAVN.mjs} +1 -1
  24. package/dist/rolldown/shared/{load-config-O4G7NVNA.mjs → load-config-Dd7jKGUy.mjs} +1 -1
  25. package/dist/rolldown/shared/{normalize-string-or-regex-Cj-DgIV1.mjs → normalize-string-or-regex-CFtim40S.mjs} +1 -1
  26. package/dist/rolldown/shared/{parse-CQfUbVuN.mjs → parse-rvxTD36n.mjs} +2 -2
  27. package/dist/rolldown/shared/{resolve-tsconfig-CE3HNSOK.mjs → resolve-tsconfig-D2vSIIkR.mjs} +2 -2
  28. package/dist/rolldown/shared/{rolldown-qV_fUwyM.mjs → rolldown-Bblizyw1.mjs} +4 -4
  29. package/dist/rolldown/shared/{transform-WmU_cI8e.d.mts → transform--WSMLt1x.d.mts} +1 -1
  30. package/dist/rolldown/shared/{watch-BNIsji74.mjs → watch-DPvOlccK.mjs} +5 -5
  31. package/dist/rolldown/utils-index.d.mts +3 -3
  32. package/dist/rolldown/utils-index.mjs +15 -13
  33. package/dist/tsdown/{build-D_enfyvD-X5SFXZZc.js → build-D_enfyvD-tOzhITac.js} +1076 -20
  34. package/dist/tsdown/{debug-CKcBYQLP-avlAPNcV.js → debug-CKcBYQLP-By_AQqN8.js} +3 -3
  35. package/dist/tsdown/{detect-DGhJGEqb-CGd2brAW.js → detect-DGhJGEqb-LL52mV6u.js} +1 -1
  36. package/dist/tsdown/{dist-BZO8q3c0.js → dist-BsS7BOcb.js} +5 -5
  37. package/dist/tsdown/index-types.d.ts +4 -4
  38. package/dist/tsdown/index.js +4 -4
  39. package/dist/tsdown/internal-DSmmwu4u.js +3 -0
  40. package/dist/tsdown/{main-Jz_9T-KA.js → main-Bcv7jU2b.js} +210 -196
  41. package/dist/tsdown/npm_entry_picomatch.cjs +10 -6
  42. package/dist/tsdown/npm_entry_tree-kill.cjs +4 -2
  43. package/dist/tsdown/{resolver-cwLsPb2o-BqQjnCbF.js → resolver-cwLsPb2o-Bb9SDBm6.js} +2 -2
  44. package/dist/tsdown/run.js +6 -6
  45. package/dist/tsdown/{src-D5keKqGd.js → src-JVSpR8xt.js} +5 -5
  46. package/dist/tsdown/{target-Bab3CUeB-CERZYTwS.js → target-Bab3CUeB-8PBzMh3p.js} +5 -5
  47. package/dist/tsdown/{tsc-DmzrnJwy.js → tsc-B8FD48Oc.js} +3 -3
  48. package/dist/tsdown/tsdown-css.js +5 -5
  49. package/dist/tsdown/tsdown-exe.js +4 -4
  50. package/dist/vite/client/bundledDevClient.mjs +393 -27
  51. package/dist/vite/client/client.mjs +20 -14
  52. package/dist/vite/node/chunks/build.js +70 -64
  53. package/dist/vite/node/chunks/dist.js +36 -29
  54. package/dist/vite/node/chunks/dist2.js +193 -149
  55. package/dist/vite/node/chunks/node.js +1047 -875
  56. package/dist/vite/node/chunks/postcss-import.js +23 -25
  57. package/dist/vite/node/index.d.ts +63 -58
  58. package/dist/vite/node/module-runner.d.ts +13 -13
  59. package/dist/vite/node/module-runner.js +24 -19
  60. package/package.json +32 -26
  61. package/dist/rolldown/shared/binding-DwUQWZOo.mjs +0 -662
  62. package/dist/tsdown/dist-CMKwGGNp.js +0 -1059
  63. package/dist/tsdown/internal-DyaNxVWW.js +0 -3
@@ -65,20 +65,22 @@ function normalizeString(path, allowAboveRoot) {
65
65
  else if (char === "/") break;
66
66
  else char = "/";
67
67
  if (char === "/") {
68
- if (lastSlash !== index - 1 && dots !== 1) if (dots === 2) {
69
- if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== "." || res[res.length - 2] !== ".") {
70
- if (res.length > 2) {
71
- let lastSlashIndex = res.lastIndexOf("/");
72
- lastSlashIndex === -1 ? (res = "", lastSegmentLength = 0) : (res = res.slice(0, lastSlashIndex), lastSegmentLength = res.length - 1 - res.lastIndexOf("/")), lastSlash = index, dots = 0;
73
- continue;
74
- }
75
- if (res.length > 0) {
76
- res = "", lastSegmentLength = 0, lastSlash = index, dots = 0;
77
- continue;
68
+ if (lastSlash !== index - 1 && dots !== 1) {
69
+ if (dots === 2) {
70
+ if (res.length < 2 || lastSegmentLength !== 2 || res[res.length - 1] !== "." || res[res.length - 2] !== ".") {
71
+ if (res.length > 2) {
72
+ let lastSlashIndex = res.lastIndexOf("/");
73
+ lastSlashIndex === -1 ? (res = "", lastSegmentLength = 0) : (res = res.slice(0, lastSlashIndex), lastSegmentLength = res.length - 1 - res.lastIndexOf("/")), lastSlash = index, dots = 0;
74
+ continue;
75
+ }
76
+ if (res.length > 0) {
77
+ res = "", lastSegmentLength = 0, lastSlash = index, dots = 0;
78
+ continue;
79
+ }
78
80
  }
79
- }
80
- allowAboveRoot && (res += res.length > 0 ? "/.." : "..", lastSegmentLength = 2);
81
- } else res.length > 0 ? res += `/${path.slice(lastSlash + 1, index)}` : res = path.slice(lastSlash + 1, index), lastSegmentLength = index - lastSlash - 1;
81
+ allowAboveRoot && (res += res.length > 0 ? "/.." : "..", lastSegmentLength = 2);
82
+ } else res.length > 0 ? res += `/${path.slice(lastSlash + 1, index)}` : res = path.slice(lastSlash + 1, index), lastSegmentLength = index - lastSlash - 1;
83
+ }
82
84
  lastSlash = index, dots = 0;
83
85
  } else char === "." && dots !== -1 ? ++dots : dots = -1;
84
86
  }
@@ -652,14 +654,18 @@ const createInvokeableTransport = (transport) => {
652
654
  } } : {},
653
655
  async send(data) {
654
656
  if (invokeableTransport.send) {
655
- if (!isConnected) if (connectingPromise) await connectingPromise;
656
- else throw new SendBeforeConnectError("send was called before connect");
657
+ if (!isConnected) {
658
+ if (connectingPromise) await connectingPromise;
659
+ else throw new SendBeforeConnectError("send was called before connect");
660
+ }
657
661
  await invokeableTransport.send(data);
658
662
  }
659
663
  },
660
664
  async invoke(name, data) {
661
- if (!isConnected) if (connectingPromise) await connectingPromise;
662
- else throw new SendBeforeConnectError("invoke was called before connect");
665
+ if (!isConnected) {
666
+ if (connectingPromise) await connectingPromise;
667
+ else throw new SendBeforeConnectError("invoke was called before connect");
668
+ }
663
669
  return invokeableTransport.invoke(name, data);
664
670
  }
665
671
  };
@@ -1156,9 +1162,8 @@ var ModuleRunner = class {
1156
1162
  if (visited.has(mod.id)) return !1;
1157
1163
  visited.add(mod.id);
1158
1164
  for (let importedModuleId of mod.imports) {
1159
- if (callstack.includes(importedModuleId)) return !0;
1160
1165
  let importedModule = this.evaluatedModules.getModuleById(importedModuleId);
1161
- if (importedModule?.promise && !importedModule.evaluated && this.isCircularRequest(importedModule, callstack, visited)) return !0;
1166
+ if (!(!importedModule?.promise || importedModule.evaluated) && (callstack.includes(importedModuleId) || this.isCircularRequest(importedModule, callstack, visited))) return !0;
1162
1167
  }
1163
1168
  return !1;
1164
1169
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voidzero-dev/vite-plus-core",
3
- "version": "0.2.8",
3
+ "version": "0.3.0",
4
4
  "description": "The Unified Toolchain for the Web",
5
5
  "homepage": "https://viteplus.dev/guide",
6
6
  "bugs": {
@@ -89,8 +89,14 @@
89
89
  "default": "./dist/rolldown/plugins-index.mjs",
90
90
  "types": "./dist/rolldown/plugins-index.d.mts"
91
91
  },
92
- "./rolldown/pluginutils": "./dist/pluginutils/index.mjs",
93
- "./rolldown/pluginutils/filter": "./dist/pluginutils/filter/index.mjs",
92
+ "./rolldown/pluginutils": {
93
+ "default": "./dist/pluginutils/index.mjs",
94
+ "types": "./dist/pluginutils/index.d.mts"
95
+ },
96
+ "./rolldown/pluginutils/filter": {
97
+ "default": "./dist/pluginutils/filter/index.mjs",
98
+ "types": "./dist/pluginutils/filter/index.d.mts"
99
+ },
94
100
  "./rolldown/utils": {
95
101
  "default": "./dist/rolldown/utils-index.mjs",
96
102
  "types": "./dist/rolldown/utils-index.d.mts"
@@ -101,8 +107,8 @@
101
107
  "./types/internal/*": null
102
108
  },
103
109
  "dependencies": {
104
- "@oxc-project/runtime": "=0.142.0",
105
- "@oxc-project/types": "=0.142.0",
110
+ "@oxc-project/runtime": "=0.146.0",
111
+ "@oxc-project/types": "=0.146.0",
106
112
  "lightningcss": "^1.33.0",
107
113
  "postcss": "^8.5.6",
108
114
  "yuku-codegen": "^0.5.44",
@@ -113,35 +119,35 @@
113
119
  "@babel/generator": "^7.28.5",
114
120
  "@babel/parser": "^7.28.5",
115
121
  "@babel/types": "^7.28.5",
116
- "@emnapi/core": "2.0.0-alpha.3",
117
- "@emnapi/runtime": "2.0.0-alpha.3",
122
+ "@emnapi/core": "2.0.0-alpha.4",
123
+ "@emnapi/runtime": "2.0.0-alpha.4",
118
124
  "@napi-rs/cli": "^3.8.2",
119
125
  "@oxc-node/cli": "^0.1.0",
120
126
  "@tsdown/css": "^0.22.14",
121
127
  "@tsdown/exe": "^0.22.14",
122
- "@vitejs/devtools": "^0.4.10",
128
+ "@vitejs/devtools": "^0.5.2",
123
129
  "es-module-lexer": "^1.7.0",
124
130
  "hookable": "^6.0.1",
125
131
  "magic-string": "^0.30.21",
126
- "oxc-parser": "=0.142.0",
127
- "oxfmt": "=0.61.0",
132
+ "oxc-parser": "=0.146.0",
133
+ "oxfmt": "=0.64.0",
128
134
  "picocolors": "^1.1.1",
129
- "picomatch": "^4.0.3",
135
+ "picomatch": "^4.0.2",
130
136
  "pkg-types": "^2.3.0",
131
137
  "rolldown-plugin-dts": "^0.28.0",
132
- "rollup": "^4.18.0",
138
+ "rollup": "^4.60.4",
133
139
  "rollup-plugin-license": "^3.6.0",
134
- "semver": "^7.7.3",
140
+ "semver": "^7.8.0",
135
141
  "tinyglobby": "^0.2.15",
136
142
  "tree-kill": "^1.2.2",
137
143
  "tsdown": "^0.22.14",
138
- "vite": "npm:@voidzero-dev/vite-plus-core@0.2.8",
139
- "rolldown": "1.2.2"
144
+ "rolldown": "1.2.5",
145
+ "vite": "npm:@voidzero-dev/vite-plus-core@0.3.0"
140
146
  },
141
147
  "peerDependencies": {
142
148
  "@arethetypeswrong/core": "^0.18.1",
143
149
  "@types/node": "^20.19.0 || >=22.12.0",
144
- "@vitejs/devtools": "^0.4.0",
150
+ "@vitejs/devtools": "^0.4.0 || ^0.5.0",
145
151
  "esbuild": "^0.27.0 || ^0.28.0",
146
152
  "jiti": ">=1.21.0",
147
153
  "less": "^4.0.0",
@@ -212,21 +218,21 @@
212
218
  },
213
219
  "optionalDependencies": {
214
220
  "fsevents": "~2.3.3",
215
- "@voidzero-dev/vite-plus-darwin-arm64": "0.2.8",
216
- "@voidzero-dev/vite-plus-darwin-x64": "0.2.8",
217
- "@voidzero-dev/vite-plus-linux-arm64-gnu": "0.2.8",
218
- "@voidzero-dev/vite-plus-linux-arm64-musl": "0.2.8",
219
- "@voidzero-dev/vite-plus-linux-x64-gnu": "0.2.8",
220
- "@voidzero-dev/vite-plus-linux-x64-musl": "0.2.8",
221
- "@voidzero-dev/vite-plus-win32-x64-msvc": "0.2.8",
222
- "@voidzero-dev/vite-plus-win32-arm64-msvc": "0.2.8"
221
+ "@voidzero-dev/vite-plus-darwin-arm64": "0.3.0",
222
+ "@voidzero-dev/vite-plus-darwin-x64": "0.3.0",
223
+ "@voidzero-dev/vite-plus-linux-arm64-gnu": "0.3.0",
224
+ "@voidzero-dev/vite-plus-linux-arm64-musl": "0.3.0",
225
+ "@voidzero-dev/vite-plus-linux-x64-gnu": "0.3.0",
226
+ "@voidzero-dev/vite-plus-linux-x64-musl": "0.3.0",
227
+ "@voidzero-dev/vite-plus-win32-x64-msvc": "0.3.0",
228
+ "@voidzero-dev/vite-plus-win32-arm64-msvc": "0.3.0"
223
229
  },
224
230
  "engines": {
225
231
  "node": "^20.19.0 || ^22.18.0 || >=24.11.0"
226
232
  },
227
233
  "bundledVersions": {
228
- "vite": "8.2.0",
229
- "rolldown": "1.2.2",
234
+ "vite": "8.2.2",
235
+ "rolldown": "1.2.5",
230
236
  "tsdown": "0.22.14"
231
237
  },
232
238
  "scripts": {