MadLittleMods / postcss-css-variables

PostCSS plugin to transform CSS Custom Properties(CSS variables) syntax into a static representation
https://madlittlemods.github.io/postcss-css-variables/playground/
Other
536 stars 62 forks source link

Move postcss to peerDependencies #127

Closed ilfa closed 3 years ago

ilfa commented 4 years ago

It will be great not to download extra version of postcss.

More details you can find in this article https://nodejs.org/en/blog/npm/peer-dependencies/.

I can create a PR if you are ok.

MadLittleMods commented 3 years ago

@ilfa Is this the proper way to handle this nowadays? Any docs for PostCSS specifically?

Looking through a bunch of popular PostCSS plugins, they aren't doing this:

I do see that Autoprefixer does this:

ScottAwesome commented 3 years ago

@MadLittleMods since the move to postcss 8, in the Plugin BoilerPlate Repo they are showing postcss as a peerDependency.

edit: I found the migration guide, and it is now an official recommendation:

Official Migration Guide

MadLittleMods commented 3 years ago

Thanks for the context @ScottAwesome!

@ilfa Feel free to create a PR :+1:

MadLittleMods commented 3 years ago

Fixed in https://github.com/MadLittleMods/postcss-css-variables/pull/129 and shipped in postcss-css-variables@0.18.0 🚀

Thanks to @delucis for the contribution ❤️