I find the next brake,
I am adding some loaders to my webpack.config.js The code is as follows:
module.exports = {
mode: 'development',
entry: './test.js',
output: {
filename: 'bundle.js',
path: __dirname
},
module: {
loaders: [
{
test: /(\.js|.jsx)$/,
loader: 'babel',
query: {
presets: ['es2015', 'stage-2', 'react']
}
}
]
}
};
And when running the webpack watch
webpack --watch
I see the following error by console:
Invalid configuration object. Webpack has been initialized using a configuration object that does not match the schema API. - configuration.module has an unknown property 'loaders'. These properties are valid: object {exprContextCritical? exprContextRecursive ?, exprContextRegExp ?, exprContextRequest ?, noParse ?, rules ?, defaultRules ?, unknownContextCritical ?, unknownContextRecursive ?, unknownContextRegExp ?, unknownContextRequest ?, unsafeCache ?, wrappedContextCritical ?, wrappedContextRecursive ?, wrappedContextRegExp ?, strictExportPresence ?, strictThisContextOnImports? } - > Options affecting the normal modules (
NormalModuleFactory
).
It should be noted that if I delete the loaders I do not see any error