@voidzero-dev/vite-plus-core 0.1.14 → 0.1.15-alpha.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/rolldown/cli.mjs +6 -6
- package/dist/rolldown/config.mjs +2 -2
- package/dist/rolldown/experimental-index.mjs +8 -8
- package/dist/rolldown/index.mjs +4 -4
- package/dist/rolldown/parallel-plugin-worker.mjs +2 -2
- package/dist/rolldown/parse-ast-index.mjs +1 -1
- package/dist/rolldown/plugins-index.mjs +2 -2
- package/dist/rolldown/shared/{bindingify-input-options-DHK3MwUV.mjs → bindingify-input-options-BCAF6TcN.mjs} +4 -4
- package/dist/rolldown/shared/{constructors-BfnFojy3.mjs → constructors-D3ZqEbT5.mjs} +1 -1
- package/dist/rolldown/shared/{error-D8cGyrC7.mjs → error-BLhcSyeg.mjs} +1 -1
- package/dist/rolldown/shared/{load-config-DT77Jzbv.mjs → load-config-CFr1Adp9.mjs} +1 -1
- package/dist/rolldown/shared/{normalize-string-or-regex-BFB1QNW3.mjs → normalize-string-or-regex-CCT059Zu.mjs} +1 -1
- package/dist/rolldown/shared/{parse-CCDXnkPL.mjs → parse-tRtSyZ-b.mjs} +1 -1
- package/dist/rolldown/shared/{resolve-tsconfig-gxOviCVx.mjs → resolve-tsconfig-DJjTYbYr.mjs} +2 -2
- package/dist/rolldown/shared/{rolldown-DFpH3t7W.mjs → rolldown-BMLc9elZ.mjs} +1 -1
- package/dist/rolldown/shared/{rolldown-build-ZUNnA-sr.mjs → rolldown-build-CxsB9UaT.mjs} +4 -4
- package/dist/rolldown/shared/{watch-C4x8DFD_.mjs → watch-DJOwXDOi.mjs} +4 -4
- package/dist/rolldown/utils-index.mjs +2 -2
- package/dist/tsdown/build-D-zhBXEK-X12uvwLb.js +2 -0
- package/dist/tsdown/{build-CoLhkNXE-CCP1weoc.js → build-DpU0PBVv-CUY7qeWj.js} +313 -52
- package/dist/tsdown/{debug-C4FmgzkJ-PiSP_iWN.js → debug-C4FmgzkJ-A9B4RM_w.js} +2 -2
- package/dist/tsdown/{detect-DN3DXXYt-XnCR4Kxo.js → detect-DN3DXXYt-GIMDNpE1.js} +1 -1
- package/dist/tsdown/{dist-BWGgEAtQ.js → dist-BkOM3Vdg.js} +1 -1
- package/dist/tsdown/index-types.d.ts +131 -131
- package/dist/tsdown/index.js +4 -4
- package/dist/tsdown/{main-CDlTYgDd.js → main-BgAbc3Rw.js} +3 -3
- package/dist/tsdown/npm_entry_picomatch.cjs +217 -9
- package/dist/tsdown/run.js +3 -3
- package/dist/vite/client/client.mjs +4 -4
- package/dist/vite/node/chunks/build2.js +1 -0
- package/dist/vite/node/chunks/node.js +218 -10
- package/package.json +10 -10
- package/dist/tsdown/build-dhDyu66J-CpOySv4e.js +0 -2
- /package/dist/rolldown/shared/{binding-ER32uZ22.mjs → binding-CkWPGrSM.mjs} +0 -0
package/dist/tsdown/run.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { c as globalLogger, f as dim, g as yellow, r as version, t as R } from "./main-
|
|
3
|
-
import { t as enableDebug } from "./debug-C4FmgzkJ-
|
|
2
|
+
import { c as globalLogger, f as dim, g as yellow, r as version, t as R } from "./main-BgAbc3Rw.js";
|
|
3
|
+
import { t as enableDebug } from "./debug-C4FmgzkJ-A9B4RM_w.js";
|
|
4
4
|
import module, { createRequire } from "node:module";
|
|
5
5
|
import process$1 from "node:process";
|
|
6
6
|
import { VERSION } from "@voidzero-dev/vite-plus-core/rolldown";
|
|
@@ -630,7 +630,7 @@ cli.command("[...files]", "Bundle files", {
|
|
|
630
630
|
}).option("-c, --config <filename>", "Use a custom config file").option("--config-loader <loader>", "Config loader to use: auto, native, unrun", { default: "auto" }).option("--no-config", "Disable config file").option("-f, --format <format>", "Bundle format: esm, cjs, iife, umd", { default: "esm" }).option("--clean", "Clean output directory, --no-clean to disable").option("--deps.never-bundle <module>", "Mark dependencies as external").option("--minify", "Minify output").option("--devtools", "Enable devtools integration").option("--debug [feat]", "Show debug logs").option("--target <target>", "Bundle target, e.g \"es2015\", \"esnext\"").option("-l, --logLevel <level>", "Set log level: info, warn, error, silent").option("--fail-on-warn", "Fail on warnings", { default: true }).option("--no-write", "Disable writing files to disk, incompatible with watch mode").option("-d, --out-dir <dir>", "Output directory", { default: "dist" }).option("--treeshake", "Tree-shake bundle", { default: true }).option("--sourcemap", "Generate source map", { default: false }).option("--shims", "Enable cjs and esm shims ", { default: false }).option("--platform <platform>", "Target platform", { default: "node" }).option("--dts", "Generate dts files").option("--publint", "Enable publint", { default: false }).option("--attw", "Enable Are the types wrong integration", { default: false }).option("--unused", "Enable unused dependencies check", { default: false }).option("-w, --watch [path]", "Watch mode").option("--ignore-watch <path>", "Ignore custom paths in watch mode").option("--from-vite [vitest]", "Reuse config from Vite or Vitest").option("--report", "Size report", { default: true }).option("--env.* <value>", "Define compile-time env variables").option("--env-file <file>", "Load environment variables from a file, when used together with --env, variables in --env take precedence").option("--env-prefix <prefix>", "Prefix for env variables to inject into the bundle", { default: "TSDOWN_" }).option("--on-success <command>", "Command to run on success").option("--copy <dir>", "Copy files to output dir").option("--public-dir <dir>", "Alias for --copy, deprecated").option("--tsconfig <tsconfig>", "Set tsconfig path").option("--unbundle", "Unbundle mode").option("--root <dir>", "Root directory of input files").option("--exe", "Bundle as executable").option("-W, --workspace [dir]", "Enable workspace mode").option("-F, --filter <pattern>", "Filter configs (cwd or name), e.g. /pkg-name$/ or pkg-name").option("--exports", "Generate export-related metadata for package.json (experimental)").action(async (input, flags) => {
|
|
631
631
|
globalLogger.level = flags.logLevel || "info";
|
|
632
632
|
globalLogger.info(`tsdown ${dim`v${version}`} powered by rolldown ${dim`v${VERSION}`}`);
|
|
633
|
-
const { build } = await import("./build-
|
|
633
|
+
const { build } = await import("./build-D-zhBXEK-X12uvwLb.js");
|
|
634
634
|
if (input.length > 0) flags.entry = input;
|
|
635
635
|
await build(flags);
|
|
636
636
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "@vite/env";
|
|
2
|
-
//#region \0@oxc-project+runtime@0.
|
|
2
|
+
//#region \0@oxc-project+runtime@0.122.0/helpers/typeof.js
|
|
3
3
|
function _typeof(o) {
|
|
4
4
|
"@babel/helpers - typeof";
|
|
5
5
|
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
|
|
@@ -9,7 +9,7 @@ function _typeof(o) {
|
|
|
9
9
|
}, _typeof(o);
|
|
10
10
|
}
|
|
11
11
|
//#endregion
|
|
12
|
-
//#region \0@oxc-project+runtime@0.
|
|
12
|
+
//#region \0@oxc-project+runtime@0.122.0/helpers/toPrimitive.js
|
|
13
13
|
function toPrimitive(t, r) {
|
|
14
14
|
if ("object" != _typeof(t) || !t) return t;
|
|
15
15
|
var e = t[Symbol.toPrimitive];
|
|
@@ -21,13 +21,13 @@ function toPrimitive(t, r) {
|
|
|
21
21
|
return ("string" === r ? String : Number)(t);
|
|
22
22
|
}
|
|
23
23
|
//#endregion
|
|
24
|
-
//#region \0@oxc-project+runtime@0.
|
|
24
|
+
//#region \0@oxc-project+runtime@0.122.0/helpers/toPropertyKey.js
|
|
25
25
|
function toPropertyKey(t) {
|
|
26
26
|
var i = toPrimitive(t, "string");
|
|
27
27
|
return "symbol" == _typeof(i) ? i : i + "";
|
|
28
28
|
}
|
|
29
29
|
//#endregion
|
|
30
|
-
//#region \0@oxc-project+runtime@0.
|
|
30
|
+
//#region \0@oxc-project+runtime@0.122.0/helpers/defineProperty.js
|
|
31
31
|
function _defineProperty(e, r, t) {
|
|
32
32
|
return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
33
33
|
value: t,
|
|
@@ -4555,6 +4555,7 @@ var require_dist = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
4555
4555
|
return new _processor["default"](processor);
|
|
4556
4556
|
};
|
|
4557
4557
|
Object.assign(parser, selectors);
|
|
4558
|
+
delete parser.__esModule;
|
|
4558
4559
|
exports["default"] = parser;
|
|
4559
4560
|
module.exports = exports.default;
|
|
4560
4561
|
}));
|
|
@@ -39,10 +39,11 @@ import { Buffer as Buffer$1 } from "node:buffer";
|
|
|
39
39
|
import zlib from "zlib";
|
|
40
40
|
import { setTimeout as setTimeout$1 } from "node:timers/promises";
|
|
41
41
|
import * as qs from "node:querystring";
|
|
42
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
42
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/constants.js
|
|
43
43
|
var require_constants$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
44
44
|
const WIN_SLASH = "\\\\/";
|
|
45
45
|
const WIN_NO_SLASH = `[^${WIN_SLASH}]`;
|
|
46
|
+
const DEFAULT_MAX_EXTGLOB_RECURSION = 0;
|
|
46
47
|
/**
|
|
47
48
|
* Posix glob regex
|
|
48
49
|
*/
|
|
@@ -92,8 +93,10 @@ var require_constants$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
92
93
|
SEP: "\\"
|
|
93
94
|
};
|
|
94
95
|
module.exports = {
|
|
96
|
+
DEFAULT_MAX_EXTGLOB_RECURSION,
|
|
95
97
|
MAX_LENGTH: 1024 * 64,
|
|
96
98
|
POSIX_REGEX_SOURCE: {
|
|
99
|
+
__proto__: null,
|
|
97
100
|
alnum: "a-zA-Z0-9",
|
|
98
101
|
alpha: "a-zA-Z",
|
|
99
102
|
ascii: "\\x00-\\x7F",
|
|
@@ -199,7 +202,7 @@ var require_constants$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
199
202
|
};
|
|
200
203
|
}));
|
|
201
204
|
//#endregion
|
|
202
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
205
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/utils.js
|
|
203
206
|
var require_utils$2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
204
207
|
const { REGEX_BACKSLASH, REGEX_REMOVE_BACKSLASH, REGEX_SPECIAL_CHARS, REGEX_SPECIAL_CHARS_GLOBAL } = require_constants$4();
|
|
205
208
|
exports.isObject = (val) => val !== null && typeof val === "object" && !Array.isArray(val);
|
|
@@ -247,7 +250,7 @@ var require_utils$2 = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
|
247
250
|
};
|
|
248
251
|
}));
|
|
249
252
|
//#endregion
|
|
250
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
253
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/scan.js
|
|
251
254
|
var require_scan$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
252
255
|
const utils = require_utils$2();
|
|
253
256
|
const { CHAR_ASTERISK, CHAR_AT, CHAR_BACKWARD_SLASH, CHAR_COMMA, CHAR_DOT, CHAR_EXCLAMATION_MARK, CHAR_FORWARD_SLASH, CHAR_LEFT_CURLY_BRACE, CHAR_LEFT_PARENTHESES, CHAR_LEFT_SQUARE_BRACKET, CHAR_PLUS, CHAR_QUESTION_MARK, CHAR_RIGHT_CURLY_BRACE, CHAR_RIGHT_PARENTHESES, CHAR_RIGHT_SQUARE_BRACKET } = require_constants$4();
|
|
@@ -534,7 +537,7 @@ var require_scan$1 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
534
537
|
module.exports = scan;
|
|
535
538
|
}));
|
|
536
539
|
//#endregion
|
|
537
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
540
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/parse.js
|
|
538
541
|
var require_parse$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
539
542
|
const constants = require_constants$4();
|
|
540
543
|
const utils = require_utils$2();
|
|
@@ -562,6 +565,177 @@ var require_parse$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
562
565
|
const syntaxError = (type, char) => {
|
|
563
566
|
return `Missing ${type}: "${char}" - use "\\\\${char}" to match literal characters`;
|
|
564
567
|
};
|
|
568
|
+
const splitTopLevel = (input) => {
|
|
569
|
+
const parts = [];
|
|
570
|
+
let bracket = 0;
|
|
571
|
+
let paren = 0;
|
|
572
|
+
let quote = 0;
|
|
573
|
+
let value = "";
|
|
574
|
+
let escaped = false;
|
|
575
|
+
for (const ch of input) {
|
|
576
|
+
if (escaped === true) {
|
|
577
|
+
value += ch;
|
|
578
|
+
escaped = false;
|
|
579
|
+
continue;
|
|
580
|
+
}
|
|
581
|
+
if (ch === "\\") {
|
|
582
|
+
value += ch;
|
|
583
|
+
escaped = true;
|
|
584
|
+
continue;
|
|
585
|
+
}
|
|
586
|
+
if (ch === "\"") {
|
|
587
|
+
quote = quote === 1 ? 0 : 1;
|
|
588
|
+
value += ch;
|
|
589
|
+
continue;
|
|
590
|
+
}
|
|
591
|
+
if (quote === 0) {
|
|
592
|
+
if (ch === "[") bracket++;
|
|
593
|
+
else if (ch === "]" && bracket > 0) bracket--;
|
|
594
|
+
else if (bracket === 0) {
|
|
595
|
+
if (ch === "(") paren++;
|
|
596
|
+
else if (ch === ")" && paren > 0) paren--;
|
|
597
|
+
else if (ch === "|" && paren === 0) {
|
|
598
|
+
parts.push(value);
|
|
599
|
+
value = "";
|
|
600
|
+
continue;
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
value += ch;
|
|
605
|
+
}
|
|
606
|
+
parts.push(value);
|
|
607
|
+
return parts;
|
|
608
|
+
};
|
|
609
|
+
const isPlainBranch = (branch) => {
|
|
610
|
+
let escaped = false;
|
|
611
|
+
for (const ch of branch) {
|
|
612
|
+
if (escaped === true) {
|
|
613
|
+
escaped = false;
|
|
614
|
+
continue;
|
|
615
|
+
}
|
|
616
|
+
if (ch === "\\") {
|
|
617
|
+
escaped = true;
|
|
618
|
+
continue;
|
|
619
|
+
}
|
|
620
|
+
if (/[?*+@!()[\]{}]/.test(ch)) return false;
|
|
621
|
+
}
|
|
622
|
+
return true;
|
|
623
|
+
};
|
|
624
|
+
const normalizeSimpleBranch = (branch) => {
|
|
625
|
+
let value = branch.trim();
|
|
626
|
+
let changed = true;
|
|
627
|
+
while (changed === true) {
|
|
628
|
+
changed = false;
|
|
629
|
+
if (/^@\([^\\()[\]{}|]+\)$/.test(value)) {
|
|
630
|
+
value = value.slice(2, -1);
|
|
631
|
+
changed = true;
|
|
632
|
+
}
|
|
633
|
+
}
|
|
634
|
+
if (!isPlainBranch(value)) return;
|
|
635
|
+
return value.replace(/\\(.)/g, "$1");
|
|
636
|
+
};
|
|
637
|
+
const hasRepeatedCharPrefixOverlap = (branches) => {
|
|
638
|
+
const values = branches.map(normalizeSimpleBranch).filter(Boolean);
|
|
639
|
+
for (let i = 0; i < values.length; i++) for (let j = i + 1; j < values.length; j++) {
|
|
640
|
+
const a = values[i];
|
|
641
|
+
const b = values[j];
|
|
642
|
+
const char = a[0];
|
|
643
|
+
if (!char || a !== char.repeat(a.length) || b !== char.repeat(b.length)) continue;
|
|
644
|
+
if (a === b || a.startsWith(b) || b.startsWith(a)) return true;
|
|
645
|
+
}
|
|
646
|
+
return false;
|
|
647
|
+
};
|
|
648
|
+
const parseRepeatedExtglob = (pattern, requireEnd = true) => {
|
|
649
|
+
if (pattern[0] !== "+" && pattern[0] !== "*" || pattern[1] !== "(") return;
|
|
650
|
+
let bracket = 0;
|
|
651
|
+
let paren = 0;
|
|
652
|
+
let quote = 0;
|
|
653
|
+
let escaped = false;
|
|
654
|
+
for (let i = 1; i < pattern.length; i++) {
|
|
655
|
+
const ch = pattern[i];
|
|
656
|
+
if (escaped === true) {
|
|
657
|
+
escaped = false;
|
|
658
|
+
continue;
|
|
659
|
+
}
|
|
660
|
+
if (ch === "\\") {
|
|
661
|
+
escaped = true;
|
|
662
|
+
continue;
|
|
663
|
+
}
|
|
664
|
+
if (ch === "\"") {
|
|
665
|
+
quote = quote === 1 ? 0 : 1;
|
|
666
|
+
continue;
|
|
667
|
+
}
|
|
668
|
+
if (quote === 1) continue;
|
|
669
|
+
if (ch === "[") {
|
|
670
|
+
bracket++;
|
|
671
|
+
continue;
|
|
672
|
+
}
|
|
673
|
+
if (ch === "]" && bracket > 0) {
|
|
674
|
+
bracket--;
|
|
675
|
+
continue;
|
|
676
|
+
}
|
|
677
|
+
if (bracket > 0) continue;
|
|
678
|
+
if (ch === "(") {
|
|
679
|
+
paren++;
|
|
680
|
+
continue;
|
|
681
|
+
}
|
|
682
|
+
if (ch === ")") {
|
|
683
|
+
paren--;
|
|
684
|
+
if (paren === 0) {
|
|
685
|
+
if (requireEnd === true && i !== pattern.length - 1) return;
|
|
686
|
+
return {
|
|
687
|
+
type: pattern[0],
|
|
688
|
+
body: pattern.slice(2, i),
|
|
689
|
+
end: i
|
|
690
|
+
};
|
|
691
|
+
}
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
};
|
|
695
|
+
const getStarExtglobSequenceOutput = (pattern) => {
|
|
696
|
+
let index = 0;
|
|
697
|
+
const chars = [];
|
|
698
|
+
while (index < pattern.length) {
|
|
699
|
+
const match = parseRepeatedExtglob(pattern.slice(index), false);
|
|
700
|
+
if (!match || match.type !== "*") return;
|
|
701
|
+
const branches = splitTopLevel(match.body).map((branch) => branch.trim());
|
|
702
|
+
if (branches.length !== 1) return;
|
|
703
|
+
const branch = normalizeSimpleBranch(branches[0]);
|
|
704
|
+
if (!branch || branch.length !== 1) return;
|
|
705
|
+
chars.push(branch);
|
|
706
|
+
index += match.end + 1;
|
|
707
|
+
}
|
|
708
|
+
if (chars.length < 1) return;
|
|
709
|
+
return `${chars.length === 1 ? utils.escapeRegex(chars[0]) : `[${chars.map((ch) => utils.escapeRegex(ch)).join("")}]`}*`;
|
|
710
|
+
};
|
|
711
|
+
const repeatedExtglobRecursion = (pattern) => {
|
|
712
|
+
let depth = 0;
|
|
713
|
+
let value = pattern.trim();
|
|
714
|
+
let match = parseRepeatedExtglob(value);
|
|
715
|
+
while (match) {
|
|
716
|
+
depth++;
|
|
717
|
+
value = match.body.trim();
|
|
718
|
+
match = parseRepeatedExtglob(value);
|
|
719
|
+
}
|
|
720
|
+
return depth;
|
|
721
|
+
};
|
|
722
|
+
const analyzeRepeatedExtglob = (body, options) => {
|
|
723
|
+
if (options.maxExtglobRecursion === false) return { risky: false };
|
|
724
|
+
const max = typeof options.maxExtglobRecursion === "number" ? options.maxExtglobRecursion : constants.DEFAULT_MAX_EXTGLOB_RECURSION;
|
|
725
|
+
const branches = splitTopLevel(body).map((branch) => branch.trim());
|
|
726
|
+
if (branches.length > 1) {
|
|
727
|
+
if (branches.some((branch) => branch === "") || branches.some((branch) => /^[*?]+$/.test(branch)) || hasRepeatedCharPrefixOverlap(branches)) return { risky: true };
|
|
728
|
+
}
|
|
729
|
+
for (const branch of branches) {
|
|
730
|
+
const safeOutput = getStarExtglobSequenceOutput(branch);
|
|
731
|
+
if (safeOutput) return {
|
|
732
|
+
risky: true,
|
|
733
|
+
safeOutput
|
|
734
|
+
};
|
|
735
|
+
if (repeatedExtglobRecursion(branch) > max) return { risky: true };
|
|
736
|
+
}
|
|
737
|
+
return { risky: false };
|
|
738
|
+
};
|
|
565
739
|
/**
|
|
566
740
|
* Parse the given input string.
|
|
567
741
|
* @param {String} input
|
|
@@ -689,6 +863,8 @@ var require_parse$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
689
863
|
token.prev = prev;
|
|
690
864
|
token.parens = state.parens;
|
|
691
865
|
token.output = state.output;
|
|
866
|
+
token.startIndex = state.index;
|
|
867
|
+
token.tokensIndex = tokens.length;
|
|
692
868
|
const output = (opts.capture ? "(" : "") + token.open;
|
|
693
869
|
increment("parens");
|
|
694
870
|
push({
|
|
@@ -705,6 +881,30 @@ var require_parse$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
705
881
|
extglobs.push(token);
|
|
706
882
|
};
|
|
707
883
|
const extglobClose = (token) => {
|
|
884
|
+
const literal = input.slice(token.startIndex, state.index + 1);
|
|
885
|
+
const analysis = analyzeRepeatedExtglob(input.slice(token.startIndex + 2, state.index), opts);
|
|
886
|
+
if ((token.type === "plus" || token.type === "star") && analysis.risky) {
|
|
887
|
+
const safeOutput = analysis.safeOutput ? (token.output ? "" : ONE_CHAR) + (opts.capture ? `(${analysis.safeOutput})` : analysis.safeOutput) : void 0;
|
|
888
|
+
const open = tokens[token.tokensIndex];
|
|
889
|
+
open.type = "text";
|
|
890
|
+
open.value = literal;
|
|
891
|
+
open.output = safeOutput || utils.escapeRegex(literal);
|
|
892
|
+
for (let i = token.tokensIndex + 1; i < tokens.length; i++) {
|
|
893
|
+
tokens[i].value = "";
|
|
894
|
+
tokens[i].output = "";
|
|
895
|
+
delete tokens[i].suffix;
|
|
896
|
+
}
|
|
897
|
+
state.output = token.output + open.output;
|
|
898
|
+
state.backtrack = true;
|
|
899
|
+
push({
|
|
900
|
+
type: "paren",
|
|
901
|
+
extglob: true,
|
|
902
|
+
value,
|
|
903
|
+
output: ""
|
|
904
|
+
});
|
|
905
|
+
decrement("parens");
|
|
906
|
+
return;
|
|
907
|
+
}
|
|
708
908
|
let output = token.close + (opts.capture ? ")" : "");
|
|
709
909
|
let rest;
|
|
710
910
|
if (token.type === "negate") {
|
|
@@ -1388,7 +1588,7 @@ var require_parse$4 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1388
1588
|
module.exports = parse;
|
|
1389
1589
|
}));
|
|
1390
1590
|
//#endregion
|
|
1391
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
1591
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/lib/picomatch.js
|
|
1392
1592
|
var require_picomatch$3 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1393
1593
|
const scan = require_scan$1();
|
|
1394
1594
|
const parse = require_parse$4();
|
|
@@ -1595,6 +1795,14 @@ var require_picomatch$3 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1595
1795
|
* Compile a regular expression from the `state` object returned by the
|
|
1596
1796
|
* [parse()](#parse) method.
|
|
1597
1797
|
*
|
|
1798
|
+
* ```js
|
|
1799
|
+
* const picomatch = require('picomatch');
|
|
1800
|
+
* const state = picomatch.parse('*.js');
|
|
1801
|
+
* // picomatch.compileRe(state[, options]);
|
|
1802
|
+
*
|
|
1803
|
+
* console.log(picomatch.compileRe(state));
|
|
1804
|
+
* //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/
|
|
1805
|
+
* ```
|
|
1598
1806
|
* @param {Object} `state`
|
|
1599
1807
|
* @param {Object} `options`
|
|
1600
1808
|
* @param {Boolean} `returnOutput` Intended for implementors, this argument allows you to return the raw output from the parser.
|
|
@@ -1616,10 +1824,10 @@ var require_picomatch$3 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1616
1824
|
*
|
|
1617
1825
|
* ```js
|
|
1618
1826
|
* const picomatch = require('picomatch');
|
|
1619
|
-
*
|
|
1620
|
-
* // picomatch.compileRe(state[, options]);
|
|
1827
|
+
* // picomatch.makeRe(state[, options]);
|
|
1621
1828
|
*
|
|
1622
|
-
*
|
|
1829
|
+
* const result = picomatch.makeRe('*.js');
|
|
1830
|
+
* console.log(result);
|
|
1623
1831
|
* //=> /^(?:(?!\.)(?=.)[^/]*?\.js)$/
|
|
1624
1832
|
* ```
|
|
1625
1833
|
* @param {String} `state` The object returned from the `.parse` method.
|
|
@@ -1675,7 +1883,7 @@ var require_picomatch$3 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
1675
1883
|
module.exports = picomatch;
|
|
1676
1884
|
}));
|
|
1677
1885
|
//#endregion
|
|
1678
|
-
//#region ../../node_modules/.pnpm/picomatch@4.0.
|
|
1886
|
+
//#region ../../node_modules/.pnpm/picomatch@4.0.4/node_modules/picomatch/index.js
|
|
1679
1887
|
var require_picomatch$2 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
1680
1888
|
const pico = require_picomatch$3();
|
|
1681
1889
|
const utils = require_utils$2();
|
|
@@ -5294,7 +5502,7 @@ const init = WebAssembly.compile(E()).then(WebAssembly.instantiate).then((({ exp
|
|
|
5294
5502
|
C = A;
|
|
5295
5503
|
}));
|
|
5296
5504
|
//#endregion
|
|
5297
|
-
//#region ../../node_modules/.pnpm/fdir@6.5.0_picomatch@4.0.
|
|
5505
|
+
//#region ../../node_modules/.pnpm/fdir@6.5.0_picomatch@4.0.4/node_modules/fdir/dist/index.mjs
|
|
5298
5506
|
var __require = /* @__PURE__ */ createRequire$1(import.meta.url);
|
|
5299
5507
|
function cleanPath(path) {
|
|
5300
5508
|
let normalized = normalize$1(path);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@voidzero-dev/vite-plus-core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.15-alpha.1",
|
|
4
4
|
"description": "The Unified Toolchain for the Web",
|
|
5
5
|
"homepage": "https://viteplus.dev/guide",
|
|
6
6
|
"bugs": {
|
|
@@ -100,7 +100,7 @@
|
|
|
100
100
|
"./types/internal/*": null
|
|
101
101
|
},
|
|
102
102
|
"dependencies": {
|
|
103
|
-
"@oxc-project/runtime": "=0.
|
|
103
|
+
"@oxc-project/runtime": "=0.122.0",
|
|
104
104
|
"@oxc-project/types": "=0.122.0",
|
|
105
105
|
"lightningcss": "^1.30.2",
|
|
106
106
|
"postcss": "^8.5.6"
|
|
@@ -127,14 +127,14 @@
|
|
|
127
127
|
"semver": "^7.7.3",
|
|
128
128
|
"tinyglobby": "^0.2.15",
|
|
129
129
|
"tree-kill": "^1.2.2",
|
|
130
|
-
"tsdown": "^0.21.
|
|
131
|
-
"rolldown": "1.0.0-rc.
|
|
132
|
-
"vite": "npm:@voidzero-dev/vite-plus-core@0.1.
|
|
130
|
+
"tsdown": "^0.21.5",
|
|
131
|
+
"rolldown": "1.0.0-rc.12",
|
|
132
|
+
"vite": "npm:@voidzero-dev/vite-plus-core@0.1.15-alpha.1"
|
|
133
133
|
},
|
|
134
134
|
"peerDependencies": {
|
|
135
135
|
"@arethetypeswrong/core": "^0.18.1",
|
|
136
|
-
"@tsdown/css": "0.21.
|
|
137
|
-
"@tsdown/exe": "0.21.
|
|
136
|
+
"@tsdown/css": "0.21.5",
|
|
137
|
+
"@tsdown/exe": "0.21.5",
|
|
138
138
|
"@types/node": "^20.19.0 || >=22.12.0",
|
|
139
139
|
"@vitejs/devtools": "^0.1.0",
|
|
140
140
|
"esbuild": "^0.27.0",
|
|
@@ -147,7 +147,7 @@
|
|
|
147
147
|
"sugarss": "^5.0.0",
|
|
148
148
|
"terser": "^5.16.0",
|
|
149
149
|
"tsx": "^4.8.1",
|
|
150
|
-
"typescript": "^5.0.0",
|
|
150
|
+
"typescript": "^5.0.0 || ^6.0.0",
|
|
151
151
|
"unplugin-unused": "^0.5.0",
|
|
152
152
|
"yaml": "^2.4.2"
|
|
153
153
|
},
|
|
@@ -215,8 +215,8 @@
|
|
|
215
215
|
},
|
|
216
216
|
"bundledVersions": {
|
|
217
217
|
"vite": "8.0.2",
|
|
218
|
-
"rolldown": "1.0.0-rc.
|
|
219
|
-
"tsdown": "0.21.
|
|
218
|
+
"rolldown": "1.0.0-rc.12",
|
|
219
|
+
"tsdown": "0.21.5"
|
|
220
220
|
},
|
|
221
221
|
"scripts": {
|
|
222
222
|
"build": "oxnode -C dev ./build.ts"
|
|
File without changes
|