tomastrajan / angular-ngrx-material-starter

Angular, NgRx, Angular CLI & Angular Material Starter Project
https://tomastrajan.github.io/angular-ngrx-material-starter
MIT License
2.83k stars 917 forks source link

Material Icons don't show up #508

Open marioagarcia opened 4 years ago

marioagarcia commented 4 years ago

Hi, when I try to use a simple mat-icon element the icon does not show up. Would you tell me what I need to override so that I can use a normal mat-icon like this:

<mat-icon>home</mat-icon>

The reason why I need to use normal mat-icons is that when trying to use the Angular Material's stepper the edit icons that the stepper uses don't show up as they should.

Thank you.

parthnayak7448 commented 4 years ago

Hey @marioagarcia did you find any solutions to use mat-icon?

tomastrajan commented 4 years ago

Hi @marioagarcia !

The icons are imported explicitly to reduce bundle size. You have to add it here

Hope that helps!

marioagarcia commented 4 years ago

Thanks for the tip. I see that is the case for font-awesome icons but not material icons. I am able to see the material icons after adding this to the index.html file:

<link href="https://fonts.googleapis.com/icon?family=Material+Icons"
      rel="stylesheet">

@parthnayak7448, hope this helps!

bhagwatipandey commented 4 years ago

Hi @marioagarcia !

The icons are imported explicitly to reduce bundle size. You have to add it here

Hope that helps!

For me it was working when I made the entry in core.module file