File tree 3 files changed +21
-3
lines changed 3 files changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,11 @@ const ModuleFederationPlugin = require("webpack").container
3
3
. ModuleFederationPlugin ;
4
4
const path = require ( "path" ) ;
5
5
6
+ // some webpack5/Node18 quirk, better than going with legacy openssl provider :shrug:
7
+ const crypto = require ( "crypto" ) ;
8
+ const crypto_orig_createHash = crypto . createHash ;
9
+ crypto . createHash = algorithm => crypto_orig_createHash ( algorithm == "md4" ? "sha256" : algorithm ) ;
10
+
6
11
module . exports = {
7
12
entry : "./index.js" ,
8
13
mode : "development" ,
@@ -12,7 +17,8 @@ module.exports = {
12
17
port : 1337
13
18
} ,
14
19
output : {
15
- publicPath : "auto"
20
+ publicPath : "auto" ,
21
+ hashFunction : "sha256"
16
22
} ,
17
23
module : {
18
24
rules : [
Original file line number Diff line number Diff line change @@ -4,6 +4,11 @@ const HtmlWebpackPlugin = require("html-webpack-plugin");
4
4
5
5
const { ModuleFederationPlugin } = webpack . container ;
6
6
7
+ // some webpack5/Node18 quirk, better than going with legacy openssl provider :shrug:
8
+ const crypto = require ( "crypto" ) ;
9
+ const crypto_orig_createHash = crypto . createHash ;
10
+ crypto . createHash = algorithm => crypto_orig_createHash ( algorithm == "md4" ? "sha256" : algorithm ) ;
11
+
7
12
module . exports = {
8
13
entry : "./index.js" ,
9
14
mode : "development" ,
@@ -13,7 +18,8 @@ module.exports = {
13
18
port : 1338
14
19
} ,
15
20
output : {
16
- publicPath : "auto"
21
+ publicPath : "auto" ,
22
+ hashFunction : "sha256"
17
23
} ,
18
24
module : {
19
25
rules : [
Original file line number Diff line number Diff line change @@ -4,6 +4,11 @@ const HtmlWebpackPlugin = require("html-webpack-plugin");
4
4
5
5
const { ModuleFederationPlugin } = webpack . container ;
6
6
7
+ // some webpack5/Node18 quirk, better than going with legacy openssl provider :shrug:
8
+ const crypto = require ( "crypto" ) ;
9
+ const crypto_orig_createHash = crypto . createHash ;
10
+ crypto . createHash = algorithm => crypto_orig_createHash ( algorithm == "md4" ? "sha256" : algorithm ) ;
11
+
7
12
module . exports = {
8
13
// no entry
9
14
entry : { } ,
@@ -14,7 +19,8 @@ module.exports = {
14
19
port : 1339
15
20
} ,
16
21
output : {
17
- publicPath : "auto"
22
+ publicPath : "auto" ,
23
+ hashFunction : "sha256"
18
24
} ,
19
25
module : {
20
26
rules : [
You can’t perform that action at this time.
0 commit comments