0

I have noticed that web essentials for visual studio creates a .css.map file when compiling less. Does this mean it is possible to navigate from a selector in the css file back to the selector in the associated less file? If so how?

Matthew
  • 1,148
  • 10
  • 17

2 Answers2

1

Yes, the idea of source maps is to map code or css from a compressed file back to the original uncompressed version.

Here is a good guide to using source maps in Chrome and Firefox.

An introduction to source maps

Colin Bacon
  • 15,436
  • 7
  • 52
  • 72
0

In VS 2013, if you enable LESS preview window, you can leverage Go To Definition command on a selector in preview to highlight the corresponding selector in LESS source. (via right-click context menu or press F12 in preview window -- see #809). When applicable, it will also load the @imported document, where the source is available.

On that note, there are precession issues with libsass' source-map. For that matter, it doesn't work well in SCSS editor.

vulcan raven
  • 32,612
  • 11
  • 57
  • 93