Skip to content

Add Source Maps option

Xample edited this page Mar 3, 2014 · 3 revisions

Source Maps can make a lot easier when debugging via Chrome or FF, and it be supported in Sass preview version (3.3.0-rc) and LESS 1.5.0.
What are Source Maps?

How to using source maps feature with Koala

By default, Koala do not provide this option, but you can increase it through the project configuration file. The Using-project-settings feature is very useful, you can set the custom settings for your project.

  1. Create the "koala-config.json" file.
    Select a project, right-click on it and choose "Project Settings" --> "new settings" --> choose the language you use. Then koala will create a "koala-config.json" file under you project directory.

  2. Add source maps option
    Find the customOptions field and add "--sourcemap".

  3. Install Sass 3.3.0-rc or LESS 1.5.0
    For install Sass: gem install sass --pre
    For install LESS: npm install -g [email protected]

  4. Set Koala to using System compiler
    Settings --> Sass/LESS --> Advanced Settings. If you have installed the compiler in your system, you can just select "Use the system compiler" option, If not, you need to fill in the full path to the executable file.

Now try compile your Sass/LESS file, it will create a map file like named style.css.map in the css output directory.