-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
PostCSS doesn't work with microbundle #7063
Comments
Thanks for raising this! Super quick investigation makes me think So the fix will be to make the necessary changes in that plugin. Not sure when we ourselves will get a chance to take a stab at it, but if anyone else is interested in trying to PR it to them here's some information about it: https://github.com/postcss/postcss/blob/main/docs/guidelines/runner.md#3-dependencies |
@adamwathan Thanks for the quick reply. I just had a quick look how you handled this in Tailwind, and it looks like there's already a workaround for my specific issue: tailwindcss/src/util/parseDependency.js Lines 42 to 46 in 3e2a067
Simply adding Not sure if you want to add this to the docs or whatever, so I'll leave this issue open for you to close. EDIT: I think |
Can confirm @AdrianMrn solution works! great, was banging my head against the wall :) |
Hey! Thank you for your bug report! I took note to fix the issue upstream in the rollup-plugin-postcss, but in the meantime you can use the workaround that @AdrianMrn provided. |
What version of Tailwind CSS are you using?
3.0.13 (latest)
What build tool (or framework if it abstracts the build tool) are you using?
What version of Node.js are you using?
16.13.2
What browser are you using?
Chrome
What operating system are you using?
macOS
Reproduction URL
https://github.com/AdrianMrn/microbundle-tailwindcss-watcher-test
Describe your issue
As per @RobinMalfait's request in this PR, we've run into an issue where, after the Tailwind watcher was removed, our stack (bundling with Microbundle) doesn't update the css automatically anymore.
Microbundle is a bundler that runs on Rollup but requires minimal configuration.
Reproduction steps:
/src/index.html
in a browser & see that the included classes are builtdiv
in index.html to e.g.bg-red-300
When locking tailwindcss to 3.0.8 (the last version to have
TAILWIND_MODE=watch
), this exact setup does work and new styles are built as expected.The text was updated successfully, but these errors were encountered: