DioxusLabs / dioxus

Fullstack app framework for web, desktop, mobile, and more.
https://dioxuslabs.com
Apache License 2.0
20.74k stars 804 forks source link

The latest version of `Tailwind` styles are not working, and hot reloading is not effective. #3013

Open wcldyx opened 3 weeks ago

wcldyx commented 3 weeks ago

Problem

The latest version of Tailwind styles are not working, and hot reloading is not effective.

Steps To Reproduce

Steps to reproduce the behavior:

Expected behavior I hope that basic features like hot reload during development and Tailwind CSS work properly.

Environment:

hardliner66 commented 2 weeks ago

Temporary workaround for tailwind:

Download tailwind.js file from https://cdn.tailwindcss.com and put it in your assets folder, then use the following to load it:

let cfg = dioxus::desktop::Config::new()
    .with_custom_head(r#"<script src="/assets/tailwind.js"></script>"#.to_string());
IroncladDev commented 2 weeks ago

You need to have a separate tailwind process running as Dioxus doesn't run it for you when you do dx serve

npx tailwindcss -i ./src/input.css -o ./assets/tailwind.css --watch

I'm also experiencing the issue on 0.6.0-alpha.2 where hot reloading is not effective on any platform. I see DEV: Hotreloaded <file> in the dev logs but there are no changes.