* fix stutter in bundle, fix nsis, fix msi bundling * fmt * rename android libname to `libmain`, rename server exe to `server` * fix hot-dog url handling * set linux product name * update schema
31 lines
596 B
Rust
31 lines
596 B
Rust
mod backend;
|
|
mod frontend;
|
|
|
|
use dioxus::prelude::*;
|
|
use frontend::*;
|
|
|
|
#[derive(Routable, PartialEq, Clone)]
|
|
enum Route {
|
|
#[layout(NavBar)]
|
|
#[route("/")]
|
|
DogView,
|
|
|
|
#[route("/favorites")]
|
|
Favorites,
|
|
}
|
|
|
|
fn main() {
|
|
// only in production should we set the URL, otherwise let `dx` do the work
|
|
#[cfg(all(not(feature = "server"), feature = "production"))]
|
|
dioxus::fullstack::set_server_url("https://hot-dog.fly.dev");
|
|
|
|
dioxus::launch(app);
|
|
}
|
|
|
|
fn app() -> Element {
|
|
rsx! {
|
|
Stylesheet { href: asset!("/assets/main.css") }
|
|
Router::<Route> {}
|
|
}
|
|
}
|