xoofx / SharpScss

A portable cross-platform pinvoke .NET wrapper around libsass to convert SCSS to CSS
BSD 2-Clause "Simplified" License
55 stars 10 forks source link

[Question] Adding Support for "generally" invalid syntax #8

Closed dansiegel closed 6 years ago

dansiegel commented 6 years ago

I'm wanting to use SharpScss to compile Scss for Xamarin.Forms. The issue is that css as implemented for Xamarin.Forms introduces ^base as valid syntax for css. This isn't generally considered valid syntax though and results in an error:

^contentpage {
  margin: 10px;
}
SharpScss.ScssException : Error: Invalid CSS after "}": expected 1 selector or at-rule, was "^contentpage {"
        on line 7 of Templates/Scss/style2.scss

Is there a way that I can add support for this syntax without disabling error detection?

xoofx commented 6 years ago

It is not really possible. SharpScss is simply a wrapper of a native library libsass so we don't have any way to change the parsing behavior (unless they introduced something recently I'm not aware of)