Reputation: 19
rake aborted!
Sass::SyntaxError: Invalid CSS after " position: ": expected expression (e.g. 1px, bold), was ";"
(in F:/OrderBooking/app/assets/stylesheets/application.css) (sass):340
Tasks: TOP => assets:precompile
In my local machine there is no error, but while deploying my application, I am getting the above error. But in my application.css
i have nothing in it.
Upvotes: 0
Views: 6770
Reputation: 17834
Syntax errors in CSS are ignored in development environment, but in production environment while precompiling assets these errors come. So to make sure your CSS has no syntax errors, every time before uploading to production, run the following command, fine if it runs successfully, if it throws error then fix the syntax error, following is the command
RAILS_ENV=development rake assets:precompile
In your case, the error says, In your application.css.scss
, in line number 340
, there's a syntax error. So you need to fix the syntax error and deploy again to Heroku.
Hope this helps!
Upvotes: 4
Reputation: 6117
I got this one time because I was trying to use <script src="
on CSS on my index.html file instead of <link rel="stylesheet" href=
Upvotes: 0