@seayoo-web/scripts 1.2.7 → 1.2.10

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 (2) hide show
  1. package/dist/index.js +23 -3
  2. package/package.json +3 -2
package/dist/index.js CHANGED
@@ -132,9 +132,29 @@ function definePageBuildConfig(option) {
132
132
  vue(),
133
133
  vueDevTools(),
134
134
  legacy({
135
- targets: ["defaults", "ie >= 10", "chrome 52"],
136
- additionalLegacyPolyfills: ["regenerator-runtime/runtime"],
137
- renderLegacyChunks: true
135
+ targets: [
136
+ "defaults",
137
+ "> 0.2%",
138
+ "last 5 versions and not dead",
139
+ "Firefox ESR",
140
+ "edge>=60",
141
+ "firefox>=60",
142
+ "chrome>=52",
143
+ "chromeAndroid>=52",
144
+ "safari>=8",
145
+ "iOS>=8"
146
+ ],
147
+ // 提高现代版本的要求防止某些杂牌浏览器的问题
148
+ modernTargets: "edge>=131, firefox>=67, chrome>=72, safari>=12, chromeAndroid>=72, iOS>=12",
149
+ // https://github.com/vitejs/vite/blob/main/packages/plugin-legacy/src/index.ts#L170
150
+ // https://unpkg.com/browse/core-js@3.41.0/
151
+ additionalLegacyPolyfills: [
152
+ "regenerator-runtime/runtime.js",
153
+ "core-js/es/array/flat",
154
+ "core-js/es/global-this",
155
+ "core-js/es/promise/all-settled",
156
+ "core-js/es/symbol"
157
+ ]
138
158
  }),
139
159
  htmlInjectPlugin({
140
160
  BUILD_TIME: envs.stamp,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seayoo-web/scripts",
3
- "version": "1.2.7",
3
+ "version": "1.2.10",
4
4
  "description": "scripts for seayoo web monorepos",
5
5
  "type": "module",
6
6
  "source": "index.ts",
@@ -47,6 +47,7 @@
47
47
  "jiti": "^2.4.2",
48
48
  "ora": "^8.2.0",
49
49
  "postcss-html": "^1.8.0",
50
+ "terser": "^5.39.0",
50
51
  "vite-plugin-stylelint": "^6.0.0",
51
52
  "vite-plugin-vue-devtools": "^7.7.2",
52
53
  "@seayoo-web/finder": "^2.0.13"
@@ -59,7 +60,7 @@
59
60
  "stylelint": "^16.15.0",
60
61
  "stylelint-config-recess-order": "^6.0.0",
61
62
  "stylelint-config-standard": "^37.0.0",
62
- "@seayoo-web/tsconfig": "^1.0.2"
63
+ "@seayoo-web/tsconfig": "^1.0.3"
63
64
  },
64
65
  "peerDependencies": {
65
66
  "eslint": "^9.19.0",