Fix throwToEscapeEventLoop function

This commit is contained in:
Ben Merritt 2019-06-05 22:51:11 -07:00
parent 54b4074369
commit 7dabad4d71
No known key found for this signature in database
GPG key ID: F8AD20ED4E6239B7
2 changed files with 3 additions and 3 deletions

View file

@ -69,9 +69,9 @@ struct EventLoopRunner<T> {
event_handler: Box<dyn FnMut(Event<T>, &mut ControlFlow)>,
}
#[wasm_bindgen]
#[wasm_bindgen(module = "/src/platform_impl/web_sys/util.js")]
extern "C" {
#[wasm_bindgen(module = "/src/platform_impl/web_sys/util.js", js_name = "throwToEscapeEventLoop")]
#[wasm_bindgen(js_name = "throwToEscapeEventLoop")]
fn throw_to_escape_event_loop();
}

View file

@ -1,3 +1,3 @@
function throwToEscapeEventLoop() {
export function throwToEscapeEventLoop() {
throw "Using exceptions for control flow, don't mind me. This isn't actually an error!";
}