Skip to content

Commit

Permalink
bugfix
Browse files Browse the repository at this point in the history
  • Loading branch information
hasanayan committed Jun 19, 2021
1 parent ce29f5e commit 9970767
Show file tree
Hide file tree
Showing 21 changed files with 5 additions and 161 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ module.exports = {
const fastRefreshEnabled = process.env.FAST_REFRESH !== "false";
const isEnvDevelopment = env === "development";

console.log(webpackConfig.plugins);
webpackConfig.output = {
...webpackConfig.output,
publicPath: "auto",
Expand All @@ -28,8 +27,9 @@ module.exports = {
};

const htmlWebpackPlugin = webpackConfig.plugins.find(
(plugin) => (plugin.constructor.name = "HtmlWebpackPlugin")
(plugin) => plugin.constructor.name === "HtmlWebpackPlugin"
);

htmlWebpackPlugin.userOptions.hash = true;
if (fastRefreshEnabled && isEnvDevelopment) {
htmlWebpackPlugin.userOptions.chunks = ["main"];
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "craco-module-federation",
"version": "1.0.1",
"version": "1.0.2",
"description": "Enable Module Federation your CRA project without ejecting or losing update support of react-scripts",
"main": "src/index.js",
"scripts": {
Expand Down
1 change: 1 addition & 0 deletions test/app1/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,4 @@
npm-debug.log*
yarn-debug.log*
yarn-error.log*
build
1 change: 0 additions & 1 deletion test/app1/build/index.html

This file was deleted.

2 changes: 0 additions & 2 deletions test/app1/build/remoteEntry.js

This file was deleted.

1 change: 0 additions & 1 deletion test/app1/build/remoteEntry.js.map

This file was deleted.

73 changes: 0 additions & 73 deletions test/app1/build/static/css/src_bootstrap_tsx.748b0cd7.chunk.css

This file was deleted.

This file was deleted.

2 changes: 0 additions & 2 deletions test/app1/build/static/js/main.891d5ece.js

This file was deleted.

1 change: 0 additions & 1 deletion test/app1/build/static/js/main.891d5ece.js.map

This file was deleted.

Loading

0 comments on commit 9970767

Please sign in to comment.