-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
@tailwindcss/line-clamp check produces an error if bundled. #10894
Comments
I got the same error after upgraded to v3.3.0 |
Hey, thank you for this bug report! 🙏 Can you provide a minimal reproduction repo that showcases this issue? It's also very odd that tools like rollup modify the intentional source code and create bugs like that 🤔. Either way, if you can provide a reproduction than I am happy to take a look for you! |
Here's a reproduction repo https://github.com/haleksandre/sveltekit-tailwind It looks like the problems occur when you use Tailwind's 'non-ESM' module such as The workaround is to install the now obsolete |
We encountered the same issue as well with webpack 5.77.0. Kinda curious though, could this be related to a We're rolling back to v3.2.7 for now since that resolves all these issues for now. |
Hey thanks again for reporting this. This has been fixed in #10919 and will be released as part of |
https://github.com/tailwindlabs/tailwindcss/blame/3809127a2ce7e8173611ae40c7a260bb56e6342f/src/util/normalizeConfig.js#L304
We use tailwind with StencilJS, which uses Rollup to generate packages. The problem with this change is that the require call is moved out of the check farther up. Now this require call is called outside the try catch and fails the whole application. Most bundlers optimize imports, especially if they have to resolve interoparability between ESM and CJS.
This is also the only require call of the whole file, the other imports use ESM.
The text was updated successfully, but these errors were encountered: