@shuvi/service 1.0.19 → 1.0.21

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.
@@ -261,7 +261,7 @@ class WebpackBundler {
261
261
  return issues;
262
262
  });
263
263
  }
264
- compiler.hooks.beforeCompile.tap('beforeCompile', () => {
264
+ compiler.hooks.invalid.tap('invalid', () => {
265
265
  if (this._startTime === null) {
266
266
  this._startTime = performance.now();
267
267
  }
@@ -27,15 +27,14 @@ function createWebpackConfig({ mode, assetPublicPath, paths, config }, _a) {
27
27
  : paths.buildDir;
28
28
  const cacheDir = paths.cacheDir;
29
29
  const publicPath = assetPublicPath;
30
- const env = config.env;
31
30
  const include = [
32
31
  paths.srcDir,
33
32
  paths.appDir,
34
33
  AppSourceRegexp,
35
34
  ...(opts.include || [])
36
35
  ];
37
- const lightningCss = !!config.experimental.lightningCss;
38
- const experimental = config.experimental;
36
+ const { env, analyze, experimental } = config;
37
+ const lightningCss = !!experimental.lightningCss;
39
38
  const jsConfig = (0, typescript_1.getJavaScriptInfo)();
40
39
  const compiler = Object.assign(Object.assign({}, config.compiler), { modularizeImports: experimental.modularizeImports, swcPlugins: experimental.swcPlugins, experimentalDecorators: Boolean((_b = jsConfig === null || jsConfig === void 0 ? void 0 : jsConfig.compilerOptions) === null || _b === void 0 ? void 0 : _b.experimentalDecorators), emitDecoratorMetadata: Boolean((_c = jsConfig === null || jsConfig === void 0 ? void 0 : jsConfig.compilerOptions) === null || _c === void 0 ? void 0 : _c.emitDecoratorMetadata) });
41
40
  if (opts.node) {
@@ -50,7 +49,8 @@ function createWebpackConfig({ mode, assetPublicPath, paths, config }, _a) {
50
49
  compiler,
51
50
  jsConfig,
52
51
  include,
53
- env
52
+ env,
53
+ analyze
54
54
  });
55
55
  }
56
56
  else {
@@ -66,7 +66,7 @@ function createWebpackConfig({ mode, assetPublicPath, paths, config }, _a) {
66
66
  jsConfig,
67
67
  include,
68
68
  env,
69
- analyze: config.analyze
69
+ analyze
70
70
  });
71
71
  }
72
72
  chain.name(opts.name);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shuvi/service",
3
- "version": "1.0.19",
3
+ "version": "1.0.21",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/shuvijs/shuvi.git",
@@ -29,15 +29,15 @@
29
29
  "@babel/generator": "7.14.5",
30
30
  "@babel/parser": "7.14.7",
31
31
  "@babel/traverse": "7.14.7",
32
- "@shuvi/hook": "1.0.19",
33
- "@shuvi/router": "1.0.19",
34
- "@shuvi/runtime": "1.0.19",
35
- "@shuvi/shared": "1.0.19",
36
- "@shuvi/toolpack": "1.0.19",
37
- "@shuvi/utils": "1.0.19",
38
- "@shuvi/error-overlay": "1.0.19",
39
- "@shuvi/telemetry": "1.0.19",
40
- "@shuvi/trace": "1.0.19",
32
+ "@shuvi/hook": "1.0.21",
33
+ "@shuvi/router": "1.0.21",
34
+ "@shuvi/runtime": "1.0.21",
35
+ "@shuvi/shared": "1.0.21",
36
+ "@shuvi/toolpack": "1.0.21",
37
+ "@shuvi/utils": "1.0.21",
38
+ "@shuvi/error-overlay": "1.0.21",
39
+ "@shuvi/telemetry": "1.0.21",
40
+ "@shuvi/trace": "1.0.21",
41
41
  "commander": "5.1.0",
42
42
  "comment-json": "4.2.2",
43
43
  "cross-spawn": "7.0.3",