use axum::{extract::ws::WebSocketUpgrade, response::Html, routing::get, Router}; use dioxus::prelude::*; fn app(cx: Scope) -> Element { let mut num = use_state(cx, || 0); cx.render(rsx! { div { "hello axum! {num}" button { onclick: move |_| num += 1, "Increment" } } }) } #[tokio::main] async fn main() { pretty_env_logger::init(); let addr: std::net::SocketAddr = ([127, 0, 0, 1], 3030).into(); let view = dioxus_liveview::LiveViewPool::new(); let app = Router::new() .route( "/", get(move || async move { Html(format!( r#"