@uni_toolkit/unplugin-json-optimization 0.0.15 → 0.0.16
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/{chunk-ZDVJORCZ.js → chunk-A5XPZGFI.js} +3 -2
- package/dist/index.cjs +3 -2
- package/dist/index.js +1 -1
- package/dist/vite.cjs +3 -2
- package/dist/vite.js +1 -1
- package/dist/webpack.cjs +3 -2
- package/dist/webpack.js +1 -1
- package/package.json +1 -1
|
@@ -30,7 +30,8 @@ var unpluginFactory = (options = {
|
|
|
30
30
|
}
|
|
31
31
|
},
|
|
32
32
|
generateBundle(_, bundle) {
|
|
33
|
-
|
|
33
|
+
const bundleEntries = Object.entries(bundle);
|
|
34
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
34
35
|
if (chunk.type !== "chunk" || !chunk.moduleIds || !chunk.moduleIds.length || fileName.includes("/")) {
|
|
35
36
|
continue;
|
|
36
37
|
}
|
|
@@ -43,7 +44,7 @@ var unpluginFactory = (options = {
|
|
|
43
44
|
}
|
|
44
45
|
}
|
|
45
46
|
const keys = Array.from(pathMap.keys());
|
|
46
|
-
for (const [fileName, chunk] of
|
|
47
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
47
48
|
if (chunk.type !== "chunk") {
|
|
48
49
|
continue;
|
|
49
50
|
}
|
package/dist/index.cjs
CHANGED
|
@@ -66,7 +66,8 @@ var unpluginFactory = (options = {
|
|
|
66
66
|
}
|
|
67
67
|
},
|
|
68
68
|
generateBundle(_, bundle) {
|
|
69
|
-
|
|
69
|
+
const bundleEntries = Object.entries(bundle);
|
|
70
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
70
71
|
if (chunk.type !== "chunk" || !chunk.moduleIds || !chunk.moduleIds.length || fileName.includes("/")) {
|
|
71
72
|
continue;
|
|
72
73
|
}
|
|
@@ -79,7 +80,7 @@ var unpluginFactory = (options = {
|
|
|
79
80
|
}
|
|
80
81
|
}
|
|
81
82
|
const keys = Array.from(pathMap.keys());
|
|
82
|
-
for (const [fileName, chunk] of
|
|
83
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
83
84
|
if (chunk.type !== "chunk") {
|
|
84
85
|
continue;
|
|
85
86
|
}
|
package/dist/index.js
CHANGED
package/dist/vite.cjs
CHANGED
|
@@ -67,7 +67,8 @@ var unpluginFactory = (options = {
|
|
|
67
67
|
}
|
|
68
68
|
},
|
|
69
69
|
generateBundle(_, bundle) {
|
|
70
|
-
|
|
70
|
+
const bundleEntries = Object.entries(bundle);
|
|
71
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
71
72
|
if (chunk.type !== "chunk" || !chunk.moduleIds || !chunk.moduleIds.length || fileName.includes("/")) {
|
|
72
73
|
continue;
|
|
73
74
|
}
|
|
@@ -80,7 +81,7 @@ var unpluginFactory = (options = {
|
|
|
80
81
|
}
|
|
81
82
|
}
|
|
82
83
|
const keys = Array.from(pathMap.keys());
|
|
83
|
-
for (const [fileName, chunk] of
|
|
84
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
84
85
|
if (chunk.type !== "chunk") {
|
|
85
86
|
continue;
|
|
86
87
|
}
|
package/dist/vite.js
CHANGED
package/dist/webpack.cjs
CHANGED
|
@@ -67,7 +67,8 @@ var unpluginFactory = (options = {
|
|
|
67
67
|
}
|
|
68
68
|
},
|
|
69
69
|
generateBundle(_, bundle) {
|
|
70
|
-
|
|
70
|
+
const bundleEntries = Object.entries(bundle);
|
|
71
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
71
72
|
if (chunk.type !== "chunk" || !chunk.moduleIds || !chunk.moduleIds.length || fileName.includes("/")) {
|
|
72
73
|
continue;
|
|
73
74
|
}
|
|
@@ -80,7 +81,7 @@ var unpluginFactory = (options = {
|
|
|
80
81
|
}
|
|
81
82
|
}
|
|
82
83
|
const keys = Array.from(pathMap.keys());
|
|
83
|
-
for (const [fileName, chunk] of
|
|
84
|
+
for (const [fileName, chunk] of bundleEntries) {
|
|
84
85
|
if (chunk.type !== "chunk") {
|
|
85
86
|
continue;
|
|
86
87
|
}
|
package/dist/webpack.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uni_toolkit/unplugin-json-optimization",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.16",
|
|
5
5
|
"description": "A plugin to optimize json files generation",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"homepage": "https://github.com/uni-toolkit/uni-toolkit/tree/main/packages/unplugin-json-optimization",
|