@ -10,9 +10,9 @@ crate-type = ["cdylib"]
[dependencies]
seed = "^0.3.0"
seed = "^0.3.1"
wasm-bindgen = "^0.2.37"
wasm-bindgen = "^0.2.40"
web-sys = "^0.3.6"
web-sys = "^0.3.17"
# For serialization, eg sending requests to a server. Otherwise, not required.
serde = { version = "^1.0.85", features = ['derive'] }
@ -35,11 +35,13 @@ fn update(msg: Msg, model: &mut Model) -> Update<Msg> {
// View
fn view(model: &Model) -> El<Msg> {
fn view(model: &Model) -> Vec<El<Msg>> {
vec![
button![
simple_ev(Ev::Click, Msg::Increment),
format!("Hello, World × {}", model.val)
]
}
#[wasm_bindgen]