Closed shawnmmatthews closed 5 years ago
Ok so it does work with emotion, but for some reason not styled components. Is this expected behavior?
Hey @shawnmmatthews
The group
class should be used as a standard class name within your app. Here’s an example that I have confirmed works in create-react-app
with emotion
and styled-components
:
import tw from 'tailwind.macro'
let Example = tw.div`group-hover:bg-blue-500`
function App() {
return (
<div className="group">
<Example>Hello, world</Example>
</div>
)
}
Also, in case you didn’t know, all variants are availabe regardless of your Tailwind variants
config.
Thanks @bradlc my mistake!
Hey @bradlc
Thanks for all your work on this.
With tailwindcss 1.0.1 and tailwind.macro 1.0.0-alpha 8
I'm getting an error anytime I use group or group-hover.
Error: tailwind.macro: Couldn’t resolve Tailwind class name: group Learn more: https://www.npmjs.com/package/tailwind.macro
or if I remove group
Error: tailwind.macro: Couldn’t resolve Tailwind class name: group-hover Learn more: https://www.npmjs.com/package/tailwind.macro
I'm using your example over at - https://github.com/jlengstorf/gatsby-tailwind-demo/pull/8
Except, I have updated tailwind.config.js as follows
This component however is yeilding errors on group and group-hover.
Any thoughts? Is there anything else that I can provide that might help in debugging this?