You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
an open question is whether we specify any default plugins, such as what css-modulesify does. specifically i'm thinking of postcss-import, perhaps also a way to pass values around (like this but in our own way).
I reckon including postcss-import is a good call; if any other plugins should be included too this would be the right place to discuss.
Hmm, css-variables could perhaps be a solution to this? - it'd be cool if variables would trickle through to child nodes; perhaps with a global flag set or smth
Perhaps if a stylesheet is imported / declared, but not defined to a variable (e.g. prefix) it is treated as global - intentionally, because no prefix is being used. Do you reckon that's sane behavior?
Alright so postcss-import is not going to fly - even though it's a sync operation, it presumes it's async and starts doing hairy .then() stuff.
Given that we already have syntax for to solve this e.g.
sheetify('module-from-npm')
I don't think there's a need to include this plugin specifically.
I'm going to close this issue for now, as it's holding up a v4 release - going to add tests for module imports tho, as they're not currently being tested I believe.
If any other plugins should perhaps be included, I reckon we should open separate issues for that. Thanks!
Reviving this, as it can be useful for more complex css libs to split up their deps into multiple files (see css-wipe).
This does require that index.js performs actions in an async fashion, as PostCSS decided to support async calls for their api - postcss/postcss-import#41 - big fat refactor is needed for this to work.
I would personally prefer if sheetify didn't come with a lot of plugins. It would be better if you could add them in as you need them with sheetify-postcss.
Activity
yoshuawuyts commentedon Feb 8, 2016
Hmm,
css-variablescould perhaps be a solution to this? - it'd be cool if variables would trickle through to child nodes; perhaps with a global flag set or smthyoshuawuyts commentedon Feb 8, 2016
Perhaps if a stylesheet is imported / declared, but not defined to a variable (e.g.
prefix) it is treated as global - intentionally, because no prefix is being used. Do you reckon that's sane behavior?yoshuawuyts commentedon Feb 9, 2016
Alright so
postcss-importis not going to fly - even though it's a sync operation, it presumes it's async and starts doing hairy.then()stuff.Given that we already have syntax for to solve this e.g.
I don't think there's a need to include this plugin specifically.
I'm going to close this issue for now, as it's holding up a
v4release - going to add tests for module imports tho, as they're not currently being tested I believe.If any other plugins should perhaps be included, I reckon we should open separate issues for that. Thanks!
yoshuawuyts commentedon Feb 15, 2016
Reviving this, as it can be useful for more complex css libs to split up their deps into multiple files (see css-wipe).
This does require that
index.jsperforms actions in an async fashion, asPostCSSdecided to support async calls for their api - postcss/postcss-import#41 - big fat refactor is needed for this to work.bcomnes commentedon Oct 2, 2016
I would personally prefer if sheetify didn't come with a lot of plugins. It would be better if you could add them in as you need them with sheetify-postcss.
yoshuawuyts commentedon Oct 2, 2016
@bcomnes yup on board with you here