FortAwesome / angular-fontawesome

Official Angular component for Font Awesome 5+
https://fontawesome.com
MIT License
1.49k stars 152 forks source link

All icons work on local but only some work on live. #286

Closed saffabook closed 3 years ago

saffabook commented 3 years ago

I get this error with fontawesome on angular projects

ERROR Error: Could not find icon with iconName= and prefix=fas in the icon library.

The code to display it is like this

<fa-icon
            class="Awards-mainIcon"
            [icon]="config.iconSelected" // everything works, except diamond, works on local but no live?
            [@rubberBand]="rubberBand"
        ></fa-icon>

However, I don't get any errors on the local project. All other fonts are working as normal. It is just for diamond.

devoto13 commented 3 years ago

@saffabook It is not possible to say anything specific with this information, so you'll have to debug the problem yourself. Question you may consider: What it this config.iconSelected? Who sets it? Is it icon definition or icon lookup? In later case: is icon added to the library? How it is added there? Why does your code behave different in dev vs prod?

Please provide a minimal reproduction if you still believe that this is a bug in angular-fontawesome implementation.

saffabook commented 3 years ago

@devoto13 you were right! It was a server issue that was causing the bug. What threw me off was the possibility of adding FAS into there. It is closed.