Build error with 1.7.1 when using Angular Material
See original GitHub issueVersions
<!--
Angular CLI: 1.7.0
Node: 8.9.1
OS: darwin x64
Angular: 5.2.6
... animations, common, compiler, compiler-cli, core, forms
... http, language-service, platform-browser
... platform-browser-dynamic, router, service-worker
@angular/cdk: 5.2.2
@angular/cli: 1.7.1
@angular/flex-layout: 2.0.0-beta.12
@angular/material: 5.2.2
@angular-devkit/build-optimizer: 0.3.1
@angular-devkit/core: 0.3.1
@angular-devkit/schematics: 0.3.1
@ngtools/json-schema: 1.2.0
@ngtools/webpack: 1.10.0
@schematics/angular: 0.3.1
@schematics/package-update: 0.3.1
typescript: 2.6.2
webpack: 3.11.0
-->
Repro steps
git clone https://github.com/ngx-rocket/generator-ngx-rocket
npm link .
mkdir repro && cd repro
ngx new
. Select all default options but choose “Angular Material” for the UI questionnpm run e2e
Observed behavior
With angular-cli@1.7.1
I have this error when I build a project using Angular Material:
ERROR in ./node_modules/raw-loader!./node_modules/postcss-loader/lib??embedded!./node_modules/sass-loader/lib/loader.js??ref--8-3!./src/main.scss
(Emitted value instead of an instance of Error) CssSyntaxError: /Users/noda/github/generator-ngx-app/sample/node_modules/material-design-icons/iconfont/material-icons.css:10:12: Can't resolve '../node_modules/material-design-icons/iconfont/MaterialIcons-Regular.ttf)%20format(%27truetype%27' in '/Users/noda/github/generator-ngx-app/sample/src'
8 | url(MaterialIcons-Regular.woff2) format('woff2'),
9 | url(MaterialIcons-Regular.woff) format('woff'),
> 10 | url(MaterialIcons-Regular.ttf) format('truetype');
| ^
11 | }
When reverting back to angular-cli@1.7.0
everything works perfectly.
Desired behavior
App builds correctly with angular-cli@1.7.1
Issue Analytics
- State:
- Created 6 years ago
- Reactions:26
- Comments:18 (5 by maintainers)
Top Results From Across the Web
My project using angular CLI 1.7.4 what will be the right ...
Kindly guide me on which angular Material version will be the best suited for my project. Please find the error messages below: ERROR...
Read more >angular-material - npm
Start using angular-material in your project by running `npm i angular-material`. There are 338 other projects in the npm registry using ...
Read more >Getting started - Angular Material
This guide explains how to set up your Angular project to begin using Angular Material. It includes information on prerequisites, installing Angular ...
Read more >Web Libraries in Jars - WebJars
angular -material, org.webjars, angular-material ... angular-bootstrap-show-errors, org.webjars.bower, angular-bootstrap-show-errors, 2.3.0.
Read more >Create separate module for angular material components
Angular Material is the design framework developed especially for the angular framework. Angular material provides so many design components ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Same issue.
There is a serious problem in CLI management which needs to be solved.
First, it’s the third times we have a CSS regression issue in minor or patch releases, just in the last few weeks. It’s not acceptable in such an important project. Tests are clearly insufficient.
Then and most importantly, it’s not normal to have to wait so long for regressions fixes, just because the CLI team sticks to a completely inflexible and arbitrary calendar. Regressions should be fixed and new patch releases published immediately, like in any other library. I really don’t understand this way of managing Angular (and I’m not alone on this point). All process are automated so it’s easy to publish a new release.
Roughly the same error is happening with Devextreme icons when trying to load them using angular-cli 1.7.1. Reverting to 1.7.0 also solves this for me.