Skip to content

Commit

Permalink
console_error_panic_hook at the disco
Browse files Browse the repository at this point in the history
  • Loading branch information
simonft committed Jan 16, 2024
1 parent 1188dca commit 923e33a
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 1 deletion.
11 changes: 11 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions meatweb/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ itertools = "0.12.0"
gloo = { version = "0.11.0", features = ["timers"]}
charming = { version = "0.3.1", features = ["wasm"] }
chrono = "0.4.31"
console_error_panic_hook = "0.1.7"

[dependencies.web-sys]
version = "0.3.66"
Expand Down
3 changes: 2 additions & 1 deletion meatweb/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ mod bluetooth;
mod chart;
mod history;

use std::collections::BTreeMap;
use std::{collections::BTreeMap, panic};

use bluetooth::{get_characteristics_and_listeners_from_service, show_connected, ConnectionState};
use history::LogItem;
Expand Down Expand Up @@ -138,5 +138,6 @@ fn App() -> impl IntoView {
}

fn main() {
panic::set_hook(Box::new(console_error_panic_hook::hook));
leptos::mount_to_body(|| view! { <App/> })
}

0 comments on commit 923e33a

Please sign in to comment.