问答详情
源自:-

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

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


提问者:慕的地1264731 2018-04-10 17:35

个回答

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

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