Reputation: 11756
I've imported a few different components in my React project, and most of them have .css files with preset style settings. For the most part, I've been manually changing the CSS files to suit my needs. Is there a way to change the CSS directly from React? That is, is there similar to jquery where i can find the corresponding classes and change the attributes?
Upvotes: 8
Views: 39408
Reputation: 3296
For small changes here and there you can use React Inline Styles.
If you want to modify more things, you can create css/less/scss files that are local to your components and override the styles of imported components there. Here's a good example. Make sure to check the webpack configs that make that work.
Upvotes: 3