Skip to content

Commit

Permalink
Replace deprecated [hash] in the config
Browse files Browse the repository at this point in the history
  • Loading branch information
nemanjaglumac committed May 17, 2021
1 parent 1ca8280 commit 778ed18
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const config = (module.exports = {
output: {
path: BUILD_PATH + "/app/dist",
// NOTE: the filename on disk won't include "?[chunkhash]" but the URL in index.html generated by HtmlWebpackPlugin will:
filename: "[name].bundle.js?[hash]",
filename: "[name].bundle.js?[chunkhash]",
publicPath: "app/dist/",
},

Expand Down Expand Up @@ -181,7 +181,7 @@ const config = (module.exports = {

if (NODE_ENV === "hot") {
// suffixing with ".hot" allows us to run both `yarn run build-hot` and `yarn run test` or `yarn run test-watch` simultaneously
config.output.filename = "[name].hot.bundle.js?[hash]";
config.output.filename = "[name].hot.bundle.js?[contenthash]";

// point the publicPath (inlined in index.html by HtmlWebpackPlugin) to the hot-reloading server
config.output.publicPath =
Expand Down

0 comments on commit 778ed18

Please sign in to comment.