@seayoo-web/scripts 2.0.6 → 2.0.8
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.js +10 -4
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -150,12 +150,16 @@ function definePageBuildConfig(option) {
|
|
|
150
150
|
const gitInfo = onlyBuild ? null : await getCommitInfo(command, mode, envs.page, envs.deployTo || "");
|
|
151
151
|
const isProductMode = mode === "production" || mode === "prod";
|
|
152
152
|
const trunkMap = {
|
|
153
|
+
...manualChunks,
|
|
153
154
|
"naive-ui": "naive-ui",
|
|
154
155
|
html2canvas: "html2canvas",
|
|
155
156
|
thinkingdata: "thinkingdata",
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
157
|
+
pinia: "vue",
|
|
158
|
+
"vue-router": "vue",
|
|
159
|
+
"plugin-vue:": "vue",
|
|
160
|
+
"/vue/": "vue",
|
|
161
|
+
"/@vue": "vue",
|
|
162
|
+
node_modules: "vendor"
|
|
159
163
|
};
|
|
160
164
|
const trunkKeys = Object.keys(trunkMap).sort((a, b) => a === "node_modules" ? 1 : b === "node_modules" ? -1 : 0);
|
|
161
165
|
const trunkFn = function(id) {
|
|
@@ -169,7 +173,7 @@ function definePageBuildConfig(option) {
|
|
|
169
173
|
outDir: join(process.cwd(), "./dist"),
|
|
170
174
|
assetsDir: "assets",
|
|
171
175
|
reportCompressedSize: false,
|
|
172
|
-
sourcemap: command === "build" && !!envs.sentryAuthToken,
|
|
176
|
+
sourcemap: command === "build" && !!envs.sentryAuthToken ? "hidden" : false,
|
|
173
177
|
...build,
|
|
174
178
|
rollupOptions: {
|
|
175
179
|
output: {
|
|
@@ -213,6 +217,8 @@ function definePageBuildConfig(option) {
|
|
|
213
217
|
...plugins,
|
|
214
218
|
command === "build" && envs.deployTo && !onlyBuild && gitInfo ? viteDeployPlugin({
|
|
215
219
|
deployTo: envs.deployTo,
|
|
220
|
+
// 忽略 js sourcemap 文件
|
|
221
|
+
ignoreFiles: ["*.js.map"],
|
|
216
222
|
user: envs.deployUser,
|
|
217
223
|
key: envs.deployKey,
|
|
218
224
|
debug: envs.deployDebug,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@seayoo-web/scripts",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.8",
|
|
4
4
|
"description": "scripts for seayoo web repos",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"source": "index.ts",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"terser": "^5.39.0",
|
|
51
51
|
"vite-plugin-stylelint": "^6.0.0",
|
|
52
52
|
"vite-plugin-vue-devtools": "^7.7.5",
|
|
53
|
-
"@seayoo-web/finder": "^2.0.
|
|
53
|
+
"@seayoo-web/finder": "^2.0.15"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
56
|
"@types/fs-extra": "^11.0.4",
|