Can't load ion-icons on macbook (ionic 4.0.0)

Hi everybody,

yesterday i cloned my repo on my macbook and had seen, that the mac couldn’t load any ionic icon.
This error occurs:

GET http://localhost:8100/svg/md-trash.svg 404 (Not Found)
GET http://localhost:8100/svg/ios-menu.svg 404 (Not Found)

But on my Ubuntu workspace everything is fine, there is see every icon.

Any idea how to solve this?

1 Like

Hi @Driesel :wave:

Are you using or have you used a previous alpha/beta/rc of Ionic 4 before? Maybe you’re missing the task that the Angular CLI needs to copy the SVGs to the right place in angular.json, like described in here: https://github.com/ionic-team/ionic/blob/master/CHANGELOG.md#400-rc1-2019-01-09

You can find the whole updated angular.json file here: https://github.com/ionic-team/starters/blob/master/angular/base/angular.json

Best,
Rodrigo

2 Likes

Thanks @FdezRomero for this good answer!

You were right, i hadn’t changed the angular.json. I have copied it from github.

But the problem still exists. It still cannot load any ionicon-svg. :tired_face:

I too have this issue, have upgrade all npms but there 4 svg icons that are not found for both ios and md. :disappointed_relieved:

(also have latest angular.json)

EDIT: followed the advice here

Cleared Site Data from Chrome >> Dev Tools >> Clear site data, also re-emptied cache and now they show up :grin:

HTH

1 Like

@Driesel I saw you marked my answer as the solution. Did it finally work? Did you also have to do something else?

1 Like

Yes, because i need to do both:

  1. updating angular.json
  2. clear cache
1 Like

tank you, solved my problem!

1 Like