1

I added my angular project for open sans and i added this <link rel="stylesheet" href="../node_modules/open-sans-fontface/open-sans.css"> in header,

when i run the project on localhost , that node_module working fine. but i hosted my project , that <link rel="stylesheet" href="../node_modules/open-sans-fontface/open-sans.css"> not working . anyone know how to fix that issue .

Thanks

core114
  • 5,155
  • 16
  • 92
  • 189
  • Have you looked at this: https://stackoverflow.com/questions/46363468/importing-style-sheets-in-angular4 – Linh Nov 13 '19 at 04:47

1 Answers1

1

Instead of using the <link> tag, you can import your styles in angular.json

"styles": [ "./node_modules/open-sans-fontface/open-sans.css" ]

all these style files will be affected globally.

Azkar Moulana
  • 854
  • 1
  • 8
  • 14