nth-omega requires $nth argument as a string #42

underscorebrody opened this Issue Dec 9, 2012 · 1 comment


None yet

2 participants

Due to the way SASS evaluates expressions, any complex argument to the nth-omega mixin will not give the expected result unless the argument is passed as a string.

Problematic example:

li { @include nth-omega(3n+5);} 


li:nth-omega(8n) { margin-right:0; }

Whereas this one evaluates as expected:

li { @include nth-omega("3n+5"); }


li:nth-omega(3n+5) { margin-right:0; }

I've tried out a few things and I'm not sure that there is a good solution to this other than making it clear in the documentation, as the argument has already been evaluated by the time it gets to the mixin.

kaishin commented Dec 27, 2012

@underscorebrody Thanks for reporting this issue. I agree that for the time being there isn't much that can be done to address it properly. Updating the docs.

@kaishin kaishin closed this Dec 27, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment