Add rand
Enable wasm_js on getrandom
This commit is contained in:
@@ -14,6 +14,7 @@ diesel_migrations = { version = "2.3.2", optional = true, features = [ "postgres
|
||||
dioxus = { version = "0.7.9", features = ["router", "fullstack"] }
|
||||
dotenvy = { version = "0.15.7", optional = true }
|
||||
lucide-dioxus = { version = "3.11.0", features = ["notifications"] }
|
||||
rand = "0.10.1"
|
||||
serde = { version = "1.0.228", features = ["derive"] }
|
||||
thiserror = "2.0.18"
|
||||
tracing = "0.1.44"
|
||||
@@ -31,3 +32,9 @@ server = [
|
||||
# Disabled until supported
|
||||
# desktop = ["dioxus/desktop"]
|
||||
# mobile = ["dioxus/mobile"]
|
||||
|
||||
# Enable wasm_js in getrandom when building for wasm32
|
||||
# This is a workaround for rand not exposing a wasm_js target
|
||||
# https://github.com/rust-random/rand/issues/1694#issuecomment-3846362044
|
||||
[target.'cfg(all(target_arch = "wasm32", target_os = "unknown"))'.dependencies]
|
||||
getrandom = { version = "0.4.3", features = ["wasm_js"] }
|
||||
|
||||
Reference in New Issue
Block a user