waasm compilatiion lib setup
This commit is contained in:
1173
yew-wasm/Cargo.lock
generated
Normal file
1173
yew-wasm/Cargo.lock
generated
Normal file
File diff suppressed because it is too large
Load Diff
13
yew-wasm/Cargo.toml
Normal file
13
yew-wasm/Cargo.toml
Normal file
@ -0,0 +1,13 @@
|
||||
[package]
|
||||
name = "yew-wasm"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
|
||||
[lib]
|
||||
crate-type = ["cdylib"]
|
||||
|
||||
[dependencies]
|
||||
console_error_panic_hook = "0.1.7"
|
||||
console_log = "1.0.0"
|
||||
wasm-bindgen = "0.2.93"
|
||||
yew = { git = "https://github.com/yewstack/yew/", features = ["csr"] }
|
6
yew-wasm/src/lib.rs
Normal file
6
yew-wasm/src/lib.rs
Normal file
@ -0,0 +1,6 @@
|
||||
use wasm_bindgen::prelude::*;
|
||||
|
||||
#[wasm_bindgen(start)]
|
||||
fn start() {
|
||||
std::panic::set_hook(Box::new(console_error_panic_hook::hook));
|
||||
}
|
Reference in New Issue
Block a user