Skip to content

Commit 4d0be4a

Browse files
author
Morten N.O. Henriksen
committed
1 parent 468ffe6 commit 4d0be4a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

packages/react-scripts/config/webpack.config.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,10 @@ module.exports = function (webpackEnv) {
703703
// solution that requires the user to opt into importing specific locales.
704704
// https://github.com/jmblog/how-to-optimize-momentjs-with-webpack
705705
// You can remove this if you don't use Moment.js:
706-
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
706+
new webpack.IgnorePlugin({
707+
resourceRegExp: /^\.\/locale$/,
708+
contextRegExp: /moment$/,
709+
}),
707710
// Generate a service worker script that will precache, and keep up to date,
708711
// the HTML & assets that are part of the webpack build.
709712
isEnvProduction &&

0 commit comments

Comments
 (0)