1 use wasm_bindgen::prelude::*; 2 use wasm_bindgen_test::*; 3 use web_sys::Performance; 4 5 #[wasm_bindgen] 6 extern "C" { 7 #[wasm_bindgen(js_name = performance)] 8 static PERFORMANCE: Performance; 9 } 10 11 #[wasm_bindgen_test] to_json()12fn to_json() { 13 let perf = JsValue::from(PERFORMANCE.to_json()); 14 assert!(perf.is_object()); 15 } 16