How to view the compiled css from sass files in ruby on rails?

Tags: css,ruby-on-rails,sass

Problem :

I've been learning sass on teamtreehouse and it shows how to view the css files that is compiled after writing sass. However, it's in a node environment.

How would I be able to view the compiled css from the sass code in rails? I can't seem to find a proper answer through google, or maybe there is no significance of viewing it, really? I think it would be beneficial to see what css is printed from sass code.

Solution :

maybe there is no significance of viewing it

If you know what you're doing, why would you need to view it?

SASS is a pre-processor, meaning that it does nothing by way of enhancing CSS -- it simply takes your pseudocode and turns it into actual CSS:

enter image description here

I tell you now that if you have incorrect CSS in your SASS file, or other potential issues, SASS will tell you about it. From that perspective, there's no real reason to see your compiled SASS unless you want to see the structure of your code or something.


In regards to seeing the "compiled" SASS, you'll probably be best precompiling your assets:

$ rake assets:precompile RAILS_ENV=production

This will put production-level versions of the asset files into public/..., allowing you to see what the "compiled" version of them would be.

A pain, I know, but what can you do

    CSS Howto..

    how to relate to a relative css of master page?

    How do I add a logo into the nav bar in CSS?

    How to assign a unique CSS id to each cell in a jqGrid?

    How to click on and off submenu's using javascript

    How to get odd/even coloring for IE and Firefox using CSS alone?

    How do you put two divs next to each other so they fill up the available space

    How to get jQuery UI tabs element panels and set visibility on some of them?

    How to style xml file? from xml to html using xslt and style that html using css [closed]

    How to get custom css to load after richfaces?

    How to color a responsive table in Bootstrap?

    how to align in centre using html css

    How can I create this simple form example in HTML?

    How does one override the JQuery UI styles?

    AngularJS: How to unselect a span when selecting another

    How to disable Javascript/CSS minification in ASP.NET MVC 4 Beta

    How to extend a div's width beyond its wrapper?

    How to create centered image slideshow behind website content

    Responsive design: How to open links in a modal window for desktop browsers, but not on a mobile device?

    How to write syntax in internal css to external css?

    How to create custom border style in JavaFX CSS?

    less: how to import multiple css?

    I have the CSS & JS, how do I convert that to erb for my Rails app?

    How to <%= link_to %> entire area of
  • in Ruby on Rails
  • How to Use JavaScript to Change a Cascading Style Sheet (CSS) Dynamically

    How to apply CSS styles to text only

    How to override some CSS class settings

    How do I blur an element with scroll, until it's blurred to a certain point?

    How to get the click position on a page when a css zoom is involved

    how to give css for arranging label, textbox and text area side by side in the same line

    How to Target Twitter Bootstrap <768px and 480px Breakpoints