@umijs/bundler-webpack 4.0.0-canary.20220914.1 → 4.0.0-canary.20220920.1

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.
@@ -54,7 +54,7 @@ socket.addEventListener('message', /*#__PURE__*/function () {
54
54
  console.log("[webpack] connected."); // proxy(nginx, docker) hmr ws maybe caused timeout,
55
55
  // so send ping package let ws keep alive.
56
56
 
57
- pingTimer = setInterval(function () {
57
+ pingTimer = window.setInterval(function () {
58
58
  return socket.send('ping');
59
59
  }, 30000);
60
60
  } else {
@@ -77,6 +77,7 @@ async function getConfig(opts) {
77
77
  useHash,
78
78
  staticPathPrefix: opts.staticPathPrefix !== void 0 ? opts.staticPathPrefix : "static/"
79
79
  };
80
+ config.name(opts.name);
80
81
  config.mode(opts.env);
81
82
  config.stats("none");
82
83
  Object.keys(opts.entry).forEach((key) => {
@@ -56,7 +56,10 @@ async function addJavaScriptRules(opts) {
56
56
  if (p.startsWith("./")) {
57
57
  return require.resolve(p, { paths: [cwd] });
58
58
  }
59
- return (0, import_path.dirname)(import_utils.resolve.sync(`${p}/package.json`, { basedir: cwd }));
59
+ return (0, import_path.dirname)(import_utils.resolve.sync(`${p}/package.json`, {
60
+ basedir: cwd,
61
+ preserveSymlinks: false
62
+ }));
60
63
  } catch (e) {
61
64
  if (e.code === "MODULE_NOT_FOUND") {
62
65
  throw new Error("Cannot resolve extraBabelIncludes: " + p);
package/dist/dev.js CHANGED
@@ -84,6 +84,7 @@ async function dev(opts) {
84
84
  });
85
85
  }
86
86
  const webpackConfig = await (0, import_config.getConfig)({
87
+ name: opts.mfsuStrategy === "eager" ? "eager" : void 0,
87
88
  cwd: opts.cwd,
88
89
  rootDir: opts.rootDir,
89
90
  env: import_types.Env.development,
package/dist/index.d.ts CHANGED
@@ -6,4 +6,5 @@ export * from './build';
6
6
  export * from './config/config';
7
7
  export * from './dev';
8
8
  export * from './schema';
9
+ export * from './constants';
9
10
  export { webpack };
package/dist/index.js CHANGED
@@ -21,3 +21,4 @@ __reExport(src_exports, require("./build"), module.exports);
21
21
  __reExport(src_exports, require("./config/config"), module.exports);
22
22
  __reExport(src_exports, require("./dev"), module.exports);
23
23
  __reExport(src_exports, require("./schema"), module.exports);
24
+ __reExport(src_exports, require("./constants"), module.exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@umijs/bundler-webpack",
3
- "version": "4.0.0-canary.20220914.1",
3
+ "version": "4.0.0-canary.20220920.1",
4
4
  "description": "@umijs/bundler-webpack",
5
5
  "homepage": "https://github.com/umijs/umi/tree/master/packages/bundler-webpack#readme",
6
6
  "bugs": "https://github.com/umijs/umi/issues",
@@ -34,11 +34,11 @@
34
34
  "@svgr/plugin-jsx": "^6.2.1",
35
35
  "@svgr/plugin-svgo": "^6.2.0",
36
36
  "@types/hapi__joi": "17.1.8",
37
- "@umijs/babel-preset-umi": "4.0.0-canary.20220914.1",
38
- "@umijs/bundler-utils": "4.0.0-canary.20220914.1",
37
+ "@umijs/babel-preset-umi": "4.0.0-canary.20220920.1",
38
+ "@umijs/bundler-utils": "4.0.0-canary.20220920.1",
39
39
  "@umijs/case-sensitive-paths-webpack-plugin": "^1.0.1",
40
- "@umijs/mfsu": "4.0.0-canary.20220914.1",
41
- "@umijs/utils": "4.0.0-canary.20220914.1",
40
+ "@umijs/mfsu": "4.0.0-canary.20220920.1",
41
+ "@umijs/utils": "4.0.0-canary.20220920.1",
42
42
  "cors": "^2.8.5",
43
43
  "css-loader": "6.7.1",
44
44
  "es5-imcompatible-versions": "^0.1.73",