Skip to content

Add partial support for Twin#74

Closed
mickyngub wants to merge 1 commit intotailwindlabs:mainfrom
mickyngub:main
Closed

Add partial support for Twin#74
mickyngub wants to merge 1 commit intotailwindlabs:mainfrom
mickyngub:main

Conversation

@mickyngub
Copy link
Copy Markdown

Twin supports many ways of styling an element. This PR aims ONLY to support those that use tw=""

Since Twin uses tw instead of className or class, the current version is incompatible.

-      if (['class', 'className'].includes(node.name.name)) {
+      if (['class', 'className', 'tw'].includes(node.name.name)) {

@bradlc
Copy link
Copy Markdown
Contributor

bradlc commented Jul 7, 2022

Hey @mickyngub. Thanks for taking the time to open this PR, but on this occasion I'm going to say no because the tw prop is very much a Twin thing and this plugin doesn't aim to support frameworks other than Tailwind CSS. I hope that's understandable!

@bradlc bradlc closed this Jul 7, 2022
@ljbw
Copy link
Copy Markdown

ljbw commented Oct 13, 2022

I'd like to see this merged as well. Twin macro (https://github.com/ben-rogerson/twin.macro) is a layer over tailwind that is a very useful tool for react and css-in-js. I hope you reconsider!

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

Successfully merging this pull request may close these issues.

3 participants