-
Notifications
You must be signed in to change notification settings - Fork 2
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
Will this work with components from other npm modules #7
Comments
Hi @eskimoblood. That's a good question! We are currently using postcss-theme in a large (20+ developers, multiple packages) enterprise React app. You can do it like that: webpack/webpack#2031 (comment) |
Thanks, I will give it a try. |
Just another question about node modules. If I understand it correctly it should also be possible to have the themes in its own module and use them with the following postcss setting:
|
@eskimoblood Interesting idea. We actually never tried that... But it should work. You might have to make sure the webpack CSS loader is applied to Please tell us if it works for you or why not :) |
First I need to convince the team to use css modules. |
Fair enough. FYI: If you need some more lecture or arguments for using it 😉:
We tried traditional SASS, then inline styles with Radium and eventually sticked to CSS modules. Our reasons were:
|
In our code base we split out all common stuff in its own npm module, so that every team then can install them into there project. Will your approach also work in this case, when react components comes from node modules?
The text was updated successfully, but these errors were encountered: