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

Nested CSS-in-JS #2

Closed
JadeMaveric opened this issue Jul 16, 2020 · 4 comments
Closed

Nested CSS-in-JS #2

JadeMaveric opened this issue Jul 16, 2020 · 4 comments

Comments

@JadeMaveric
Copy link
Member

Next.js doesn't support nested classes in CSS-in-JS. To fix this, I had to restructure most of it. The downside is that the naming becomes redundant and messy. We might have to look to an alternative to CSS-in-JS. #1

@vipulchodankar
Copy link
Member

Actually, i had enabled SASS support.

See here for example:
https://github.com/engicos/companion/blob/master/components/courses/ContactCard.js

@vipulchodankar
Copy link
Member

vipulchodankar commented Jul 17, 2020

I would suggest any of the following options:

  • Stick to the current method
  • Use Styled components
  • Use CSS modules with Sass - requires css files

All the options are scoped and are quite easy to use.

@JadeMaveric
Copy link
Member Author

I like the idea of using css files. Separate the logic from the styling.

@JadeMaveric
Copy link
Member Author

This will be fixed as part of #1

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

No branches or pull requests

2 participants