webpack执行时报错,无效配置对象

来源:-

慕的地1264731

2018-04-10 17:35

Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.

 - 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`).


写回答 关注

1回答

  • Rengar_fh
    2018-04-16 10:06:58

    loaders已经没有了,改成rules了,建议看下webpack的文档,里面有介绍

webpack深入与实战

webpack实战教程,用真实项目带你探索 webpack 强大的功能

86561 学习 · 721 问题

查看课程

相似问题