bradlc / babel-plugin-tailwind-components

Use Tailwind with any CSS-in-JS library
MIT License
332 stars 25 forks source link

Support for tailwind 1.2+ [Feature Request] #52

Open sanishkr opened 4 years ago

sanishkr commented 4 years ago

Please add support for new utilities introduced with tailwind 1.2 like css grid, transform, etc..

axe312ger commented 4 years ago

Just digging into the source, I guess we easily could create a PR, as I guess we only have to extend these files:

https://github.com/bradlc/babel-plugin-tailwind-components/blob/master/src/static-styles.js https://github.com/bradlc/babel-plugin-tailwind-components/blob/master/src/dynamic-styles.js

Edit:

These are the files from master, v1 work was done in next. There are many new files, but these style definitions seem to stay the same -> https://github.com/bradlc/babel-plugin-tailwind-components/blob/next/src/

sanishkr commented 4 years ago

Yeah, right. Please confirm @bradlc

sanishkr commented 4 years ago

Alright, I'm going in. Starting with staticStyles display section, and will go in that order and keep updating as in latest v1.2 of tw.

It will be great if more people join in and help, maybe take on dynamicStyles

Note: I'm not sure if updating only these 2 files will do the trick. Hope so.

ben-rogerson commented 4 years ago

There are features that have been introduced that require some major changes to the selector matching system in this package. I'm releasing a new package soon that has a high degree of support for the new v1.2 features along with a few extras. Follow for announcements

sanishkr commented 4 years ago

Thanks @ben-rogerson , shall wait for it then. When can this plugin be released? It will be great if you keep the similar tw`` literal format as in this plugin.

And you mean to say tailwindcss v1.2 features, right?

ben-rogerson commented 4 years ago

I'm planning on the first release in two weeks around Feb 26th. I've chosen to use babel-plugin-tailwind-components as a solid base so it'll include the same features, and the macro tw will definitely be kept 👍

Correct, I meant Tailwind 1.2 (I'll edit that).

ben-rogerson commented 4 years ago

Hey all, I've just released my plugin Twin 🎉

sanishkr commented 4 years ago

Thank you so much. @ben-rogerson

fvanwijk commented 4 years ago

Isn't it possible to get the features from tailwindcss instead of having to keep this plugin up to date manually?

sanishkr commented 4 years ago

It's only possible to do so up to a certain extent. I guess, @ben-rogerson is doing that in twin.macro.

lukasluecke commented 4 years ago

There is something in progress at https://github.com/ben-rogerson/twin.macro/pull/13