Question

I am trying out grunt-sass (instead of grunt-contrib-watch) to use the super speedy libsass compiler.

I've managed to get it working with compass by using a compass bower package. (https://github.com/Igosuki/compass-mixins) So the compass mixins are available. However I am getting the following error

error: only variable declarations and control directives are allowed inside functions

The error is pointing to an @if statement in one of my function calls (i've tried removing that function but it just then fails at the next @if statement).

If I omit my functions file I then get another error, pointing to one of my mixins

error: expected '{' in media query Use --force to continue.

Does anyone have any idea what's going on?

All of this stuff was working when using grunt-contrib-watch.

Thanks

Was it helpful?

Solution

With no actual sass file to look at I assume that you are using features that aren't implemented in libsass yet. To quote from the offical node-sass repo (on which grunt-sass) is based on:

The libsass library is not currently at feature parity with the 3.2 Ruby Gem that most Sass users will use, and has little-to-no support for 3.3 syntax. While we try our best to maintain feature parity with libsass, we can not enable features that have not been implemented in libsass yet.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top