question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Bug]: live reload rebuild twice when using tailwind watch

See original GitHub issue

Which Remix packages are impacted?

  • remix (Remix core)
  • create-remix
  • @remix-run/architect
  • @remix-run/cloudflare-workers
  • @remix-run/dev
  • @remix-run/express
  • @remix-run/netlify
  • @remix-run/node
  • @remix-run/react
  • @remix-run/serve
  • @remix-run/server-runtime
  • @remix-run/vercel

What version of Remix are you using?

1.0.6

Steps to Reproduce

Follow the styling section for tailwindcss in remix doc

Expected Behavior

live reload ignore the generated css file change

Actual Behavior

[1] 💿 File changed: app/styles/app.css [1] 💿 Rebuilding… [1] 💿 Rebuilt in 226ms [1] GET /form 200 - - 31.452 ms [1] 💿 File changed: app/styles/app.css [1] 💿 Rebuilding… [1] 💿 Rebuilt in 170ms

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:27 (12 by maintainers)

github_iconTop GitHub Comments

6reactions
kentcdoddscommented, Nov 29, 2021
4reactions
kentcdoddscommented, Dec 10, 2021

My PR was merged into postcss-cli!

If you update your version to 9.1.0 or greater you should no longer get a double-refresh when you save a file unless you actually do change the CSS (like in the Tailwind JIT case, if you change the class name on an element). In that case you’ll still get the double-reload. @ryanflorence had some ideas of how to avoid that once and for all. But the nice this is with postcss-cli 9.1.0 you’ll no longer get an unnecessary rebuild 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Just-in-Time Mode - Tailwind CSS
If your CSS isn't rebuilding when you change your content files, try setting TAILWIND_MODE=watch as part of your watch script to tell Tailwind...
Read more >
Tailwind not automatically updating styles without npm run ...
I'm following a course on Udemy and I've gone over every step twice but mine just isn't working like it is in the...
Read more >
Debugging Tailwind CSS and Next.js - LogRocket Blog
Using Tailwind CSS and Next.js together can be a powerful match, sometimes a few bugs get in the way. Learn to fix them...
Read more >
Adding Tailwind CSS to Phoenix 1.6 - The Pragmatic Studio
The Tailwind CLI tried to use the intermediate app.css.tailwind file as input, but it didn't yet exist because DartSass ran after Tailwind.
Read more >
Using Tailwind CSS with Create React App - Dave Ceddia
The watch:tailwind script will re-build the Tailwind output file when any CSS or SCSS files under the src directory are changed. It's explicitly ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found