Tailwind-Styled-Component
Tailwind-Styled-Component copied to clipboard
Create Tailwind CSS React components like styled components with class names on multiple lines and conditional class rendering
input: ```tsx const Div1 = tw.span`text-red-500` const Div2 = tw.div`bg-green-500` const Div3 = tw(Div1)`rounded-full` const Div4 = tw(Div2)`select-all` export default () => { return foo } ``` output: ```html foo...
I will like to use this amazing package in a project am working on, please does this support tailwind jit
$as prop appears to break className merging inheritance **Simple example** ```jsx // base tw styled component export const Heading = tw.p` text-4xl font-bold text-gray-700 ` // extend the base Heading...
Hello, it would be nice to have this in your library, or is it already there? Example of using arbitrary variants to style elements with a custom selector: ```javascript import...
Hey guys, thanks for the awesome library. I noticed there is no way to pass tw an Element to wrap on the fly. in styled-components I think you could do...
while building a UI library with this I've run into a number of scenarios where I've wanted to have the [attrs](https://styled-components.com/docs/basics#attaching-additional-props) functionality that styled has. My use case doesn't require...
When using the `$as` prop of my `StyledButton`, typescript complains with the following error on `StyledButton`: ``` Type instantiation is excessively deep and possibly infinite. ts(2589) ``` Here's a small...
When using `"type": "module"` in my `package.json`, the styled component import fails with the following error: ``` TypeError: import_tailwind_styled_components.default.button is not a function at Object. (/app/build/index.js:8624:214) at Module._compile (node:internal/modules/cjs/loader:1097:14) at...
Good afternoon, I'm having a problem with the lib typing. I create a div, but it is defined as `any`, would it be possible to force the typing to div?...
Other similar libraries like twin.macro, convert the css-in-js to css at compile time. Wanted to know if this library does the same, or does it insert css at runtime like...