I have followed the steps explained in the Angular-Cli documentation to include Font-Awesome to my project https://github.com/angular/angular-cli/blob/master/docs/documentation/stories/include-font-awesome.md
So I have this in my angular-cli.json
:
"styles": [
"../node_modules/boosted/dist/css/boosted.min.css",
"../node_modules/boosted/dist/css/orangeIcons.min.css",
"../node_modules/font-awesome/css/font-awesome.min.css",
"styles.css"
],
And everything worked fine when doing ng serve
and seeing my project on localhost:4200
.
Unfortunately, when doing ng build --prod
, it generate the dist folder, including the font-awesome files:
And I also verified if the font was added to my style.[...].bundle.css and it does:
Then, when deployed on a server (Apache Tomcat 8.5), no font-awesome icons are displayed.
I don't use SASS by the way.
Here is my Angular configuration/version:
@angular/cli: 1.4.3
node: 6.11.3
os: win32 x64
@angular/animations: 4.4.4
@angular/common: 4.4.4
@angular/compiler: 4.4.4
@angular/core: 4.4.4
@angular/forms: 4.4.4
@angular/http: 4.4.4
@angular/platform-browser: 4.4.4
@angular/platform-browser-dynamic: 4.4.4
@angular/router: 4.4.4
@angular/cli: 1.4.3
@angular/compiler-cli: 4.4.4
@angular/language-service: 4.4.4
typescript: 2.3.4
So, what can I do to make this work ?