0

after successfully installing @angular/material, @angular/cdk and @angular/animations using npm install --save, I tried to rebuild the example of a flat tree given by angular link.

After fixing the error message Could not find Angular Material core theme using this stack post solution link with adding

@import '../node_modules/@angular/material/prebuilt-themes/deeppurple-amber.css';

to my global styles.scss, it still doesn't display the tree correctly.

enter image description here

There is no error given in console. Can anyone help me to fix this issue?

student18
  • 538
  • 8
  • 26

1 Answers1

1

You need to add the Angular Material Icon Font, otherwise the icons won't be displayed properly. Add this line in your index.html file:

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

For more information check the official Getting started section of the Angular Material documentation.

Fabian Küng
  • 5,925
  • 28
  • 40