-
Notifications
You must be signed in to change notification settings - Fork 7
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
Cross reference using classNames #201
Comments
Hey @alexrah Thank you so much for your time to investigate and opening an issue. I had a quick look and it looks like you want to mix classes outside of For your case that would mean that you would have to write it like this: const Heading = styled.h2`
background-color: cyan;
&:global(.solid-variant) {
color: purple;
}
& :global(.child-item) {
color: red;
}
`; We definitely need to add this to our documentation! I will keep the issue open until that is merged |
Thanks for your explanation, I didn't play with CSS modules enough to know about it. |
No problem at all for me, but I think would be better to highlight this pattern in the documentation, perhaps in Migration from styled-components considering [#53] I don't see an easy path to solve this neither by codemod once during migration or by automatic injection. |
Thanks we will update the documentation soon |
in styled-component
ref: Pseudoelements, pseudoselectors, and nesting
the following code is valid:
but it doesn't seem to work in next-yak
demo repo
Do you have any plan of adding this feature?
The text was updated successfully, but these errors were encountered: