mirror of
https://github.com/zhigang1992/create-react-app.git
synced 2026-05-07 13:15:52 +08:00
Add empty mock for module (#5798)
This commit is contained in:
@@ -644,6 +644,7 @@ module.exports = function(webpackEnv) {
|
||||
// Some libraries import Node modules but don't use them in the browser.
|
||||
// Tell Webpack to provide empty mocks for them so importing them works.
|
||||
node: {
|
||||
module: 'empty',
|
||||
dgram: 'empty',
|
||||
fs: 'empty',
|
||||
net: 'empty',
|
||||
|
||||
Reference in New Issue
Block a user