@umijs/bundler-webpack 4.0.21 → 4.0.23
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/client/client/client.js +1 -1
- package/dist/config/config.js +1 -0
- package/dist/dev.js +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/server/server.d.ts +1 -0
- package/dist/types.d.ts +7 -2
- package/package.json +5 -5
package/client/client/client.js
CHANGED
|
@@ -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 {
|
package/dist/config/config.js
CHANGED
|
@@ -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) => {
|
package/dist/dev.js
CHANGED
|
@@ -107,7 +107,7 @@ async function dev(opts) {
|
|
|
107
107
|
analyze: process.env.ANALYZE,
|
|
108
108
|
cache: opts.cache ? {
|
|
109
109
|
...opts.cache,
|
|
110
|
-
cacheDirectory: (0, import_path.join)(cacheDirectoryPath, "bundler-webpack")
|
|
110
|
+
cacheDirectory: (0, import_path.join)(cacheDirectoryPath, opts.mfsuStrategy === "eager" ? "bundler-webpack-eager" : "bundler-webpack")
|
|
111
111
|
} : void 0,
|
|
112
112
|
pkg: opts.pkg
|
|
113
113
|
});
|
package/dist/index.d.ts
CHANGED
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/dist/server/server.d.ts
CHANGED
package/dist/types.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Config as SwcConfig } from '@swc/core';
|
|
2
2
|
import type { HttpsServerOptions, ProxyOptions } from '@umijs/bundler-utils';
|
|
3
|
-
import { Configuration } from '../compiled/webpack';
|
|
3
|
+
import webpack, { Configuration } from '../compiled/webpack';
|
|
4
4
|
import Config from '../compiled/webpack-5-chain';
|
|
5
5
|
export declare enum Env {
|
|
6
6
|
development = "development",
|
|
@@ -47,7 +47,12 @@ export interface IConfig {
|
|
|
47
47
|
alias?: Record<string, string>;
|
|
48
48
|
autoCSSModules?: boolean;
|
|
49
49
|
base?: string;
|
|
50
|
-
chainWebpack?:
|
|
50
|
+
chainWebpack?: {
|
|
51
|
+
(memo: Config, args: {
|
|
52
|
+
env: keyof typeof Env;
|
|
53
|
+
webpack: typeof webpack;
|
|
54
|
+
}): void;
|
|
55
|
+
};
|
|
51
56
|
copy?: ICopy[] | string[];
|
|
52
57
|
cssLoader?: {
|
|
53
58
|
[key: string]: any;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@umijs/bundler-webpack",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.23",
|
|
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.
|
|
38
|
-
"@umijs/bundler-utils": "4.0.
|
|
37
|
+
"@umijs/babel-preset-umi": "4.0.23",
|
|
38
|
+
"@umijs/bundler-utils": "4.0.23",
|
|
39
39
|
"@umijs/case-sensitive-paths-webpack-plugin": "^1.0.1",
|
|
40
|
-
"@umijs/mfsu": "4.0.
|
|
41
|
-
"@umijs/utils": "4.0.
|
|
40
|
+
"@umijs/mfsu": "4.0.23",
|
|
41
|
+
"@umijs/utils": "4.0.23",
|
|
42
42
|
"cors": "^2.8.5",
|
|
43
43
|
"css-loader": "6.7.1",
|
|
44
44
|
"es5-imcompatible-versions": "^0.1.73",
|