diff --git a/src/console/mod.rs b/src/console/mod.rs index eef5380..cb89b3a 100644 --- a/src/console/mod.rs +++ b/src/console/mod.rs @@ -1,3 +1,4 @@ +extern crate console_error_panic_hook; mod types; mod commands; use std::{cell::RefCell, rc::Rc}; @@ -184,6 +185,8 @@ impl Console { #[wasm_bindgen] impl Console { pub fn new() -> Console { + console_error_panic_hook::set_once(); + let root = Rc::new(RefCell::new(Directory::new("".to_string(), "".to_string()))); let console = Console {