Problem
Not possible to run examples .
Missing doc how to run them.
Examples looks they are prepared for both wasm-bindgen and wasm-pack but I think it cannot be mixed together.
wasm-pack needs this and must have main method defined within lib.rs
[lib]
crate-type = ["cdylib", "rlib"]
lib.rs
#[wasm_bindgen(start)]
pub fn run_app() {
yew::start_app::<Model>();
}
wasm-bindgen needs main.rs and must not have crate-type = ["cdylib", "rlib"] in Cargo.toml
Environment:
- Yew version [
master]
- Rust version [1.42.0]
Questionnaire
Problem
Not possible to run examples .
Missing doc how to run them.
Examples looks they are prepared for both
wasm-bindgenandwasm-packbut I think it cannot be mixed together.wasm-pack needs this and must have main method defined within
lib.rslib.rs
wasm-bindgen needs
main.rsand must not havecrate-type = ["cdylib", "rlib"]inCargo.tomlEnvironment:
master]Questionnaire