diff options
author | 2023-09-07 03:15:02 +0200 | |
---|---|---|
committer | 2023-09-07 03:15:02 +0200 | |
commit | d315e27451d46a815d18ed6037547d178413ede7 (patch) | |
tree | c6943467de79a86a9f2e789f124ccebe9966a43d | |
parent | 8cfad86ec1bb8d6f65eeec051e59b3ade982ef36 (diff) | |
download | iced-d315e27451d46a815d18ed6037547d178413ede7.tar.gz iced-d315e27451d46a815d18ed6037547d178413ede7.tar.bz2 iced-d315e27451d46a815d18ed6037547d178413ede7.zip |
Update example dependencies
-rw-r--r-- | examples/game_of_life/Cargo.toml | 2 | ||||
-rw-r--r-- | examples/integration/Cargo.toml | 9 | ||||
-rw-r--r-- | examples/pokedex/Cargo.toml | 7 | ||||
-rw-r--r-- | examples/pokedex/src/main.rs | 2 |
4 files changed, 9 insertions, 11 deletions
diff --git a/examples/game_of_life/Cargo.toml b/examples/game_of_life/Cargo.toml index f8d21c65..9b291de8 100644 --- a/examples/game_of_life/Cargo.toml +++ b/examples/game_of_life/Cargo.toml @@ -9,7 +9,7 @@ publish = false iced.workspace = true iced.features = ["debug", "canvas", "tokio"] -itertools = "0.9" +itertools = "0.11" rustc-hash.workspace = true tokio = { workspace = true, features = ["sync"] } tracing-subscriber = "0.3" diff --git a/examples/integration/Cargo.toml b/examples/integration/Cargo.toml index 4c55daa7..032cc75e 100644 --- a/examples/integration/Cargo.toml +++ b/examples/integration/Cargo.toml @@ -13,13 +13,8 @@ iced_widget.workspace = true tracing-subscriber = "0.3" [target.'cfg(target_arch = "wasm32")'.dependencies] -console_error_panic_hook = "0.1.7" -console_log = "0.2.0" +console_error_panic_hook = "0.1" +console_log = "1.0" log.workspace = true wasm-bindgen = "0.2" web-sys = { version = "0.3", features = ["Element", "HtmlCanvasElement", "Window", "Document"] } - -# This dependency a little bit quirky, it is deep in the tree and without `js` feature it -# refuses to work with `wasm32-unknown-unknown target`. Unfortunately, we need this patch -# to make it work -getrandom = { version = "0.2", features = ["js"] } diff --git a/examples/pokedex/Cargo.toml b/examples/pokedex/Cargo.toml index de8a5c17..bf7e1e35 100644 --- a/examples/pokedex/Cargo.toml +++ b/examples/pokedex/Cargo.toml @@ -21,5 +21,8 @@ default-features = false features = ["json", "rustls-tls"] [dependencies.rand] -version = "0.7" -features = ["wasm-bindgen"] +version = "0.8" + +[dependencies.getrandom] +version = "0.2" +features = ["js"] diff --git a/examples/pokedex/src/main.rs b/examples/pokedex/src/main.rs index 4482814c..8b71a269 100644 --- a/examples/pokedex/src/main.rs +++ b/examples/pokedex/src/main.rs @@ -153,7 +153,7 @@ impl Pokemon { let id = { let mut rng = rand::rngs::OsRng; - rng.gen_range(0, Pokemon::TOTAL) + rng.gen_range(0..Pokemon::TOTAL) }; let fetch_entry = async { |