From 7aa69bdfcd58778cdeb8729feb54ecf2eeb646ca Mon Sep 17 00:00:00 2001 From: Aaron Fenyes Date: Sun, 8 Dec 2024 19:59:25 -0800 Subject: [PATCH] Set the console error panic hook Turn on the browser console panic message output provided by the `console_error_panic_hook` feature. This feature was already enabled by default in our Cargo configuration, but it wasn't actually being used. --- app-proto/src/main.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app-proto/src/main.rs b/app-proto/src/main.rs index 8a012d3..f961504 100644 --- a/app-proto/src/main.rs +++ b/app-proto/src/main.rs @@ -46,6 +46,10 @@ impl AppState { } fn main() { + // set the console error panic hook + #[cfg(feature = "console_error_panic_hook")] + console_error_panic_hook::set_once(); + sycamore::render(|| { provide_context(AppState::new());