-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request]Tailwind v4 support. #4644
Comments
I am facing the same problem. When is the heroui update expected? I tried this! It didn't work. hero.ts
global.css
|
You can find heroui/packages/core/theme/src/plugin.ts Line 50 in cddba82
heroui/packages/core/theme/src/plugin.ts Line 158 in cddba82
This should be easily solved. However I don't know why Tailwind CSS requests "utilities must be a single class name and start with a lowercase letter", maybe it doesn't admit pseudo-classes. According to MDN, |
same questions |
I think this should be a high priority for Hero UI, as this is effectively a blocker for adopting Tailwind 4 for any projects that use Hero UI. Btw, thanks for the awesome UI library! |
When will the HeroUI version supporting Tailwind v4 be released? |
When will the update be released? I think the developers should have followed the development of tailwind, since hero is strictly dependent on tailwind, and released the update together with the release of tailwind 4. Otherwise, hero is useless now |
looking forward to this! |
It says in the docs. but tailwind v4 is not supported yet! |
Actually, Tailwind 4.0 Beta has been out since Nov 21, 2024, so it's been almost 3 months. Not to mention that Tailwind |
I come here almost daily to see if there is a solution and nothing 😔️. It's been a while. |
+1 |
Another vote for V4 support please! 🙏🙏🙏🙏🙏🙏🙏🙏🙏 |
Indeed @leetcow, the
It must be made sure, though, that no other Works like a charm! Looking forward to the actual release. Thx! |
tailwindcss V4 support beta released! |
I found it caused by the |
|
Hey there, there's no official support for Tailwind v4. Tailwind v4 came out with a lot of breaking changes, and HeroUI is still making changes to support TaiwlindCSS, you could give a shot using a Vite template they already tried with Tailwind v4. |
looks like Next.js is not a first class citizen anymore for NextUI 😆 |
Hey @MaximSaveliev, for
Remove all content entries from
Then you should be able to compile without errors and run P.S. I am pretty sure once out of beta the HeroUI team will release new boilerplate with all mentioned steps performed already. |
@stx-chris with all due respect, Next.js 15 does not work, as me and other people have mentioned. if you do not believe us, please share a boilerplate repo that actually works, otherwise it's futile to post instructions that we've already tried and followed. |
@FTCHD You do notice that all of us engage in these issues and conversations in our spare time to improve the quality of this library and help others being stuck with similar issues. If you invested the time to read my step-by-step guide, actually tried it yourself and not just waited until someone spends hours working out a solution and serves it readily to copy&paste, we would all have more fun in this community. I am using Since you asked, find the repo here for reference. Bear in mind that this is just a temporary issue, as the |
I have created a temporay pr with |
@stx-chris Thank you 👍, in v3 we will support pure css file to use heroui, for v2 still need to use config |
Would it be ok to share a rough ETA for HeroUI 3? Just to have an idea, thanks. |
There will be a lot of component refactoring, which should take a while, stay tune to X or discord announcements! |
Thanks for your response, i will try it if it will work for me @config "../hero_ui.ts";
@source "../../node_modules/@heroui/theme/dist/**/*.{js,ts,jsx,tsx}"; |
@MaximSaveliev have a look at the provided repo, better to forget about the suggested |
@winchesHe Thank you for your hard work making tailwind v4 working. I tried to get Hero UI working with my project but I was unable to do so. (no errors but styles don't apply). I followed standard guide for installing a new NextJS project with Tailwind v4, and Hero UI provided guide for get beta working. I've added
and within my ./tailwind.config.mjs
I have above. Basic setups such as providers are done correctly.
Please advise if I need to take extra steps to ensure HeroUI works with Tailwind v4. |
I have crucial finding that made HeroUI work with Tailwind v4. After following https://github.com/sensotix/heroui-playground-tw4 repo, |
The team has recently released version |
@kimkong88 and @stx-chris your solutions works good It start working but some styles not properly looks, is it cause of beta version or it should works? For better understanding PR (wanna have Shadcn and HeroUI libs) <Button color="primary">Button</Button>
<Form className="w-full max-w-xs" onSubmit={onSubmit}>
<Input
isRequired
errorMessage="Please enter a valid email"
label="Email"
labelPlacement="outside"
name="email"
placeholder="Enter your email"
type="email"
/>
<Button type="submit" variant="faded" color="success" className="mt-4">
Submit
</Button>
{submitted && (
<div className="text-small text-default-500">
You submitted: <code>{JSON.stringify(submitted)}</code>
</div>
)}
</Form>
<Calendar showMonthAndYearPickers aria-label="Date (Show Month and Year Picker)" /> |
Is Tailwind v4 support expected to come to HeroUI v2 soon? Or will it be delayed until HeroUI v3? |
@MaximSaveliev What I noticed in the latest beta is that for some components, such as the |
Was anyone able to make it HeroUI work with Tailwind v4 in Astro? |
It seems the bug is that its not defining the heroui styles, but its exporting the css perfectly. example CSS is being generated
but |
I was able to fix this by manually defining these values in my global.css for anyone who is still stuck on this.
please note, you still need to define the config. |
I got error Error evaluating Node.js code |
You can try upgrade |
or even easier:
at least during the beta phase. |
For Next.js, make also sure that the
or using
|
Is your feature request related to a problem? Please describe.
The new version of tailwind comes with a breaking change feature to HeroUI. v4 removes the
tailwind.config.js
.This change breaks HeroUI, making the components unable to show the right style.
Describe the solution you'd like
A new version of the docs showing how we can install HeroUI with the new version of TailwindCSS.
Describe alternatives you've considered
Trying to use tailwind's way to upgrade to v3 to v4 using
With no success. It just show this error message:
Screenshots or Videos
How a Button is showing when using the new version of Tailwindcss.
The text was updated successfully, but these errors were encountered: