Infinite Loop Issue with Vite + Tailwind v4 + Shopify Development #17227
Replies: 3 comments 1 reply
-
I'm having the same issue, though I don't know how Shopify CLI would be triggering tailwind/vite to rebuild. My setup loops even with Shopify CLI not running. |
Beta Was this translation helpful? Give feedback.
-
@moxiethunder After finally getting a chance to spend some more time on it this afternoon I believe it to be tailwind itself picking up the newly generated output file and triggering a rebuild. I think it's content detection might be getting greedy here. I've excluded Shopify's assets directory and the looping has stopped. This works with both My CSS entrypoint (
|
Beta Was this translation helpful? Give feedback.
-
I had the same issue with @import 'tailwindcss' source(none);
@source "../../**/*.{blade.php,blade.md,md,html,vue}";
@source not "../../**/_tmp/*"; Update: nope, it didn't work. As an actual solution, I had to use the |
Beta Was this translation helpful? Give feedback.
-
Hello everyone! I'm setting up a Shopify development environment using Vite and Tailwind v4 but encountering an infinite build loop issue.
Current Setup
shopify theme dev
) to sync with ShopifyThe Issue
My workflow creates an infinite build loop:
vite build --watch
compiles assets to/assets
directory/assets
(a watched directory)What Works
Suspected Cause
I believe the issue is related to how files are being built and the watch process interaction between Vite, Tailwind v4, and the Shopify CLI.
Has anyone encountered this issue or have suggestions for breaking this loop while maintaining the Vite + Tailwind v4 setup? Happy to provide more details if needed.
Beta Was this translation helpful? Give feedback.
All reactions