dioxus-letter-werefox-cafe/rust-letter-fe/build.rs

16 lines
465 B
Rust
Raw Normal View History

2023-03-28 08:21:31 -05:00
fn main() {
let mut tailwind = std::process::Command::new("npx");
tailwind.args(
"tailwindcss -i src/index.css -c tailwind.config.js -o ../public/styles/tailwind.min.css --minify"
2023-03-28 08:21:31 -05:00
.split(" "),
);
tailwind.env("NODE_ENV", "production");
match tailwind.spawn() {
Ok(_) => (),
Err(_) => {
print!("Didn't find npx in the path, can't compile CSS. Is Node installed?");
()
}
}
2023-03-28 08:21:31 -05:00
}