Replies: 1 comment
-
For the time being, I created a package that provides helpers that utilize the above types for PoC. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It's mentioned that addComponents and matchComponents allow defining components using JavaScript objects similar to Emotion.
However, looking at its type definition below, it appears that it does not provide the same developer experience as Emotion or similar libraries.
rev: https://github.com/tailwindlabs/tailwindcss/blob/master/types/config.d.ts#L11-L15
How about redefining CSSRuleObject using csstype, similar to Emotion and styled-components. For example, as shown below.
I believe this could help bridge the gap that developers transitioning from CSS-in-JS to tailwindcss might feel.
Beta Was this translation helpful? Give feedback.
All reactions