angular-cli: Webpack v2.1.0-beta.23 breaks everything
In short, please pin the webpack version to v2.1.0-beta.22. beta 23 has breaking changes: https://github.com/webpack/webpack/releases/tag/v2.1.0-beta.23 PR follows soon!
…
Please provide us with the following information:
- OS? Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?) Windows
- Versions. Please run
ng --version
. If there’s nothing outputted, please run in a Terminal:node --version
and paste the result here:angular-cli: 1.0.0-beta.14
- Repro steps. Was this an app that wasn’t created using the CLI? What change did you
do on your code? etc.
ng new foo-bar
npm start
- The log given by the failure. Normally this include a stack trace and some more information.
Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
- configuration has an unknown property 'tslint'. These properties are valid:
object { amd?, bail?, cache?, context?, devServer?, devtool?, entry, externals?, loader?, module?, name?, dependencies?, node?, output?, plugins?, profile?, recordsInputPath?, recordsOutputPath?, recordsPath?, resolve?, resolveLoader?, stats?, target?, watch?, watchOptions? }
- configuration.module has an unknown property 'preLoaders'. These properties are valid:
object { rules?, loaders?, noParse?, unknownContextRequest?, unknownContextRegExp?, unknownContextRecursive?, unknownContextCritical?, exprContextRequest?, exprContextRegExp?, exprContextRecursive?, exprContextCritical?, wrappedContextRegExp?, wrappedContextRecursive?, wrappedContextCritical? }
Options affecting the normal modules (`NormalModuleFactory`).
- configuration.node.global should be a boolean.
- configuration.resolve has an unknown property 'root'. These properties are valid:
object { modules?, descriptionFiles?, plugins?, mainFields?, aliasFields?, mainFiles?, extensions?, enforceExtension?, moduleExtensions?, enforceModuleExtension?, alias?, symlinks?, unsafeCache?, cachePredicate?, fileSystem?, resolver? }
- configuration.resolve.extensions[0] should not be empty.
WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
- configuration has an unknown property 'tslint'. These properties are valid:
object { amd?, bail?, cache?, context?, devServer?, devtool?, entry, externals?, loader?, module?, name?, dependencies?, node?, output?, plugins?, profile?, recordsInputPath?, recordsOutputPath?, recordsPath?, resolve?, resolveLoader?, stats?, target?, watch?, watchOptions? }
- configuration.module has an unknown property 'preLoaders'. These properties are valid:
object { rules?, loaders?, noParse?, unknownContextRequest?, unknownContextRegExp?, unknownContextRecursive?, unknownContextCritical?, exprContextRequest?, exprContextRegExp?, exprContextRecursive?, exprContextCritical?, wrappedContextRegExp?, wrappedContextRecursive?, wrappedContextCritical? }
Options affecting the normal modules (`NormalModuleFactory`).
- configuration.node.global should be a boolean.
- configuration.resolve has an unknown property 'root'. These properties are valid:
object { modules?, descriptionFiles?, plugins?, mainFields?, aliasFields?, mainFiles?, extensions?, enforceExtension?, moduleExtensions?, enforceModuleExtension?, alias?, symlinks?, unsafeCache?, cachePredicate?, fileSystem?, resolver? }
- configuration.resolve.extensions[0] should not be empty.
at webpack (E:\Angular2Buch\angular2-workshop-devmedia\node_modules\webpack\lib\webpack.js:16:9)
at Class.run (E:\Angular2Buch\angular2-workshop-devmedia\node_modules\angular-cli\tasks\serve-webpack.js:23:27)
at E:\Angular2Buch\angular2-workshop-devmedia\node_modules\angular-cli\commands\serve.js:84:26
at process._tickCallback (internal/process/next_tick.js:103:7)
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 9
- Comments: 18 (3 by maintainers)
Links to this issue
Commits related to this issue
- fix: pin beta package versions Fix #2234 — committed to filipesilva/angular-cli by filipesilva 8 years ago
- fix: pin beta package versions (#2236) Fix #2234 — committed to angular/angular-cli by filipesilva 8 years ago
- update angular cli + fix webpack isue https://github.com/angular/angular-cli/issues/2234#issuecomment-248173309 — committed to klaascuvelier/beautiful-places-to-run by klaascuvelier 8 years ago
Thanks @colindevs - anyone using Laravel (laravel-elixir-webpack-official) just do:
npm uninstall webpack --save-dev
followed by
npm install webpack@2.1.0-beta.22 --save-dev
Then you should be able to gulp again. Fixed the issue for me.
@colindevs as a work around you can fix webpack to
v2.1.0-beta.22
in your appspackage.json