File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed
Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ const tailwindcss = require("tailwindcss");
44const webpack = require ( "webpack" ) ;
55const MiniCssExtractPlugin = require ( "mini-css-extract-plugin" ) ;
66
7- module . exports = {
7+ module . exports = ( { includeReactHotLoader = false } = { } ) => ( {
88 context : path . resolve ( __dirname , ".." ) ,
99 resolve : {
1010 modules : [
@@ -47,7 +47,7 @@ module.exports = {
4747 "@babel/plugin-proposal-private-methods" ,
4848 "@babel/plugin-syntax-async-generators" ,
4949 "@babel/plugin-transform-regenerator" ,
50- 'react-hot-loader/babel' ,
50+ ... ( includeReactHotLoader ? [ 'react-hot-loader/babel' ] : [ ] ) ,
5151 ] ,
5252 } ,
5353 } ,
@@ -80,4 +80,4 @@ module.exports = {
8080 }
8181 ]
8282 }
83- } ;
83+ } ) ;
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ const MiniCssExtractPlugin = require("mini-css-extract-plugin");
77
88const baseConfig = require ( "./base" ) ;
99
10- module . exports = merge ( baseConfig , {
10+ module . exports = merge ( baseConfig ( { includeReactHotLoader : true } ) , {
1111 mode : "development" ,
1212 devtool : "eval-cheap-module-source-map" ,
1313 resolve : {
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ const dependencyNameToExternals = (dependencyName) => [
1212 new RegExp ( `^${ dependencyName } /.*` ) ,
1313] ;
1414
15- const common = merge ( baseConfig , {
15+ const common = merge ( baseConfig ( ) , {
1616 mode : "production" ,
1717 devtool : "source-map" ,
1818 externals : [
You can’t perform that action at this time.
0 commit comments