antoyo / relm

Idiomatic, GTK+-based, GUI library, inspired by Elm, written in Rust
MIT License
2.42k stars 79 forks source link

Hot code reload / code swap on runtime #236

Closed charafau closed 3 years ago

charafau commented 3 years ago

Hi, I really like the way this project is going I think gtk need declarative framework like this. One great improvement would be hot code reload, which would help for rapid development.

antoyo commented 3 years ago

That would be really hard. I don't think the implementation complexity outweights the benefits.

zzeroo commented 3 years ago

@charafau Dit you know cargo-watch

I use often commands like these:

cargo watch -x build

but you could also pass the run command so each time you save your file, cargo builds and runs it for you. This works very well in gtk-rs land and with relm of course, too.

cargo watch -x run
# this is also possible
cargo watch -x run --feature "foo" 
cargo watch -x "run --example bar"
charafau commented 3 years ago

@zzeroo thank you for your comment. I very casual rust developer so didn't know about this one. Will give it a go! Thanks 🙇🙏