Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Yeoman / AngularJS not loading CSS in development server

Tags:

yeoman

I'm using the AngularJS Yeoman generator (https://github.com/yeoman/generator-angular) and Express for the server. When running grunt server, it starts up my app fine and compiles .scss files into the .tmp folder in the root directory, but my pages don't automatically load that css. I have set up a link to the style/style.css stylesheet in my layout jade file.

I've also tried grunt compass, which works fine, but again, does not make it so my views actually load the css file in .tmp. I have the default compass setup in grunt.

like image 651
polyrhythm Avatar asked Nov 12 '22 07:11

polyrhythm


1 Answers

This was an issue with live-reloading that has been addressed in newer releases. Update your generators through yo or by running npm update -g generator-angular. If you want to upgrade an existing project, you can run yo angular in the same directory and choose the diff option to see the changes you have to make.

like image 94
passy Avatar answered Dec 04 '22 05:12

passy