Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass another file as an argument for plugin #457

Closed
egorvoronov opened this issue Apr 2, 2018 · 1 comment
Closed

Pass another file as an argument for plugin #457

egorvoronov opened this issue Apr 2, 2018 · 1 comment
Labels

Comments

@egorvoronov
Copy link

Hey there, thanks for amazing job.

I have a two css files, one parent.css and chunk.css, and chunk.css file has some rules that are already inside parent.css that I would like to remove from chunk.css. I started thinking that applying postcss-discard-duplicates would help here but it works only for 1 file.

So, is there any way i could pass parent css file as an argument for plugin? That way i could compare parent and chunk and remove duplicate rules from chunk (I already implemented that type of logic but it would be great if I could do this in a proper plugin way to be able to use it during the webpack build step).

Thanks

@andyjansson
Copy link
Contributor

I believe this would be something better handled by a bundler, such as webpack.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants