From 41aef381a133b802f56e72505d97cd0dca1ff386 Mon Sep 17 00:00:00 2001 From: Reece Humphreys Date: Tue, 6 Feb 2024 23:11:56 -0500 Subject: [PATCH] Improve name for WebAsm --- src/lib.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 8beb9d4..966461b 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -20,7 +20,7 @@ pub fn run(event: &impl FragmentationEvent) -> Array3 { } #[cfg(target_arch = "wasm32")] -#[wasm_bindgen] +#[wasm_bindgen(js_name = runExplosion)] pub fn run_explosion(event: &ExplosionEvent) -> JsValue { let result = run_core(event); // Convert the result to JsValue @@ -28,7 +28,7 @@ pub fn run_explosion(event: &ExplosionEvent) -> JsValue { } #[cfg(target_arch = "wasm32")] -#[wasm_bindgen] +#[wasm_bindgen(js_name = runCollision)] pub fn run_collision(event: &CollisionEvent) -> JsValue { let result = run_core(event); // Convert the result to JsValue