The A List Apart Blog Presents:

Finding Your Way with Sass Sourcemaps

Article Continues Below

The next version of Sass recently hit release candidate status, meaning it’ll be out in the wild any day now. There are some great changes coming in Sass 3.3, one of which should have developers extremely excited: sourcemaps.

Put plainly, sourcemaps are a way to map compiled code back to its native state. That may sound kind of odd, but sourcemaps will make every Sass-loving developer’s life a little bit better. Browsers that understand the generated map file will know where each and every line of code came from, down to the line number in the original Sass file, rather than the line number from the compiled CSS file.

Even in the pre-release state, sourcemaps are proving to be a big productivity boost for developers by cutting down debug time and making Sass code easier to optimize and improve. No need to wait for Sass 3.3 to be released officially: install the release candidate and try it out in your own projects!

6 Reader Comments

  1. @Sang-Min it was possible before to use Google Dev Tools with Sass sourcemaps w/o any extension. You just had to use Sass3.3 alpha and it worked like a charm.

  2. @Cat: Yep! All it does is generate a {filename}.css.map file alongside the rendered {filename}.css file. In the header of the CSS file, there is a comment directing browsers where to look for the sourcemap file.

    @Sang-Min: Awesome, hadn’t seen that! Looks great for Firefox users.

Got something to say?

We have turned off comments, but you can see what folks had to say before we did so.

More from ALA

Designed for a Dead Language

Every language app in your pocket inherited a teaching method built for Latin. Understanding why that happened is a more useful design lesson than anything the apps themselves can teach you.
Uncategorized

Design for Amiability: Lessons from Vienna

Computing was born in a Viennese café. Between 1928 and 1934, while Hitler plotted and Europe crumbled, a motley crew of mathematicians, philosophers, architects, and economists gathered weekly to puzzle out the limits of reason—and invented Computer Science in the process. What made their collaboration possible wasn't just brilliance (though they had plenty). It was amiability: the careful design of a social space where difficult people could disagree without destroying each other. Longtime A List Apart contributing author Mark Bernstein mines this forgotten history for lessons that might just save today's embattled web from its worst impulses. Spoiler: it involves better coffee service and the looming threat of public humiliation.

Discover more from A List Apart

Subscribe now to keep reading and get access to the full archive.

Continue reading