nitro-nightly 3.0.1-20251216-092308-c45e3a62 → 3.0.1-20251216-095659-bad377c5
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/_build/rolldown.mjs +2 -2
- package/dist/_build/rollup.mjs +2 -2
- package/dist/_build/shared3.mjs +55 -1121
- package/dist/_build/vite.build.mjs +1 -1
- package/dist/_build/vite.plugin.mjs +1 -1
- package/dist/_nitro3.mjs +1158 -0
- package/dist/vite.mjs +1 -1
- package/package.json +1 -1
- package/dist/_build/shared4.mjs +0 -59
package/dist/vite.mjs
CHANGED
|
@@ -14,7 +14,7 @@ import "./_build/shared2.mjs";
|
|
|
14
14
|
import "./_dev.mjs";
|
|
15
15
|
import "./_libs/@rollup/plugin-alias.mjs";
|
|
16
16
|
import "./_libs/@rollup/plugin-inject.mjs";
|
|
17
|
-
import "./
|
|
17
|
+
import "./_nitro3.mjs";
|
|
18
18
|
import "./_libs/etag.mjs";
|
|
19
19
|
import "./_libs/@jridgewell/remapping.mjs";
|
|
20
20
|
import "./_libs/@rollup/plugin-replace.mjs";
|
package/package.json
CHANGED
package/dist/_build/shared4.mjs
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import { O as relative, k as resolve, x as dirname } from "../_libs/c12.mjs";
|
|
2
|
-
import { t as glob } from "../_libs/tinyglobby.mjs";
|
|
3
|
-
import { i as a } from "../_libs/std-env.mjs";
|
|
4
|
-
import { t as runParallel } from "../_nitro2.mjs";
|
|
5
|
-
import { t as gzipSize } from "../_libs/gzip-size.mjs";
|
|
6
|
-
import { t as prettyBytes } from "../_libs/pretty-bytes.mjs";
|
|
7
|
-
import { promises } from "node:fs";
|
|
8
|
-
import { colors } from "consola/utils";
|
|
9
|
-
|
|
10
|
-
//#region src/utils/fs-tree.ts
|
|
11
|
-
async function generateFSTree(dir, options = {}) {
|
|
12
|
-
if (a) return;
|
|
13
|
-
const files = await glob("**/*.*", {
|
|
14
|
-
cwd: dir,
|
|
15
|
-
ignore: ["*.map"]
|
|
16
|
-
});
|
|
17
|
-
const items = [];
|
|
18
|
-
await runParallel(new Set(files), async (file) => {
|
|
19
|
-
const path = resolve(dir, file);
|
|
20
|
-
const src = await promises.readFile(path);
|
|
21
|
-
const size = src.byteLength;
|
|
22
|
-
const gzip = options.compressedSizes ? await gzipSize(src) : 0;
|
|
23
|
-
items.push({
|
|
24
|
-
file,
|
|
25
|
-
path,
|
|
26
|
-
size,
|
|
27
|
-
gzip
|
|
28
|
-
});
|
|
29
|
-
}, { concurrency: 10 });
|
|
30
|
-
items.sort((a$1, b) => a$1.path.localeCompare(b.path));
|
|
31
|
-
let totalSize = 0;
|
|
32
|
-
let totalGzip = 0;
|
|
33
|
-
let totalNodeModulesSize = 0;
|
|
34
|
-
let totalNodeModulesGzip = 0;
|
|
35
|
-
let treeText = "";
|
|
36
|
-
for (const [index, item] of items.entries()) {
|
|
37
|
-
let dir$1 = dirname(item.file);
|
|
38
|
-
if (dir$1 === ".") dir$1 = "";
|
|
39
|
-
const rpath = relative(process.cwd(), item.path);
|
|
40
|
-
const treeChar = index === items.length - 1 ? "└─" : "├─";
|
|
41
|
-
if (item.file.includes("node_modules")) {
|
|
42
|
-
totalNodeModulesSize += item.size;
|
|
43
|
-
totalNodeModulesGzip += item.gzip;
|
|
44
|
-
continue;
|
|
45
|
-
}
|
|
46
|
-
treeText += colors.gray(` ${treeChar} ${rpath} (${prettyBytes(item.size)})`);
|
|
47
|
-
if (options.compressedSizes) treeText += colors.gray(` (${prettyBytes(item.gzip)} gzip)`);
|
|
48
|
-
treeText += "\n";
|
|
49
|
-
totalSize += item.size;
|
|
50
|
-
totalGzip += item.gzip;
|
|
51
|
-
}
|
|
52
|
-
treeText += `${colors.cyan("Σ Total size:")} ${prettyBytes(totalSize + totalNodeModulesSize)}`;
|
|
53
|
-
if (options.compressedSizes) treeText += ` (${prettyBytes(totalGzip + totalNodeModulesGzip)} gzip)`;
|
|
54
|
-
treeText += "\n";
|
|
55
|
-
return treeText;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
//#endregion
|
|
59
|
-
export { generateFSTree as t };
|