-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Closed
Description
What version of Tailwind CSS are you using?
4.0.0-beta.4 for both tailwindcss and @tailwindcss/vite
What build tool (or framework if it abstracts the build tool) are you using?
Svelte 5/Vite
What version of Node.js are you using?
v20.15.1
What browser are you using?
Chrome
What operating system are you using?
macOS
Reproduction URL
https://github.com/huntabyte/tw-v4-monorepo-repro/tree/main
Repro info below can also be found in the README.md of the reproduction repo.
This reproduction contains the following:
uipackage which exports a (in reality would be) styledButtoncomponent which uses a primitive headless component frombits-ui.docspackage which usesuiand@tailwindcss/vite@next&tailwindcss@next.
Reproduction Steps
pnpm install && pnpm devin the root of the repo (will build theuipackage and start thedocsdev server)- Notice that the page renders and all is well.
- Open the
docs/vite.config.tsfile and addtailwindcss()to thepluginsarray / save the file. - Notice the dev server crashes with a bunch of pre-transform errors (
p has already been declared). - Remove the
tailwindcss()plugin from thedocs/vite.config.tsfile and save the file. - Notice that the dev server starts as normal.
Describe your issue
Working in a pnpm monorepo, @tailwindcss/vite@next causes the dev server to crash with vite pre-transform - p has already been declared errors.