csstools / postcss-advanced-variables

Use Sass-like variables, conditionals, and iterators in CSS
Creative Commons Zero v1.0 Universal
130 stars 33 forks source link

Fix parsing the contents of imported stylesheets #71

Closed maxmilton closed 5 years ago

maxmilton commented 5 years ago

Fixes #70 .

Passes a user defined parser to the processor.process options when running postcss for imported files. This allows for any non-standard syntax to be parsed correctly and added to the resulting AST correctly.

The postcss-import plugin does this in a similar way: https://github.com/postcss/postcss-import/blob/master/lib/process-content.js

This also fixes the following warning when using @import:

You did not set any plugins, parser, or stringifier. Right now, PostCSS does nothing. Pick plugins for your case on https://www.postcss.parts/ and use them in postcss.config.js.
jonathantneal commented 5 years ago

This is great, @MaxMilton. Thank you

agconti commented 4 years ago

I'm running into this same problem as well in https://github.com/zeit/next.js/issues/10273.

@jonathantneal Do you plan to release this fix?

maxmilton commented 4 years ago

It would be nice to see a release. I've been installing the package from my Github fork for almost a year now :grimacing: