rule.use.map is not a function
pizzarob opened this issue · comments
pizzarob commented
/universal-webpack/source/loaders.js:147:22
throws the error rule.use.map is not a function
The following is valid configuration, but universal webpack is expecting an array
{
test: /(\.js|\.jsx)$/,
exclude: /node_modules/,
use: {
loader: 'babel-loader',
options: {
presets: ['env', 'es2015', 'react', 'stage-2'],
},
},
},
Nikolay commented
According to the official Webpack documentation your config is wrong
See use
:
https://webpack.js.org/configuration/module/#rule-use