diff --git a/crates/fj-viewer/Cargo.toml b/crates/fj-viewer/Cargo.toml index fc86b1506..80e243430 100644 --- a/crates/fj-viewer/Cargo.toml +++ b/crates/fj-viewer/Cargo.toml @@ -38,8 +38,13 @@ features = ["png", "jpeg"] version = "25.0.0" features = ["webgl"] -# We don't depend on `getrandom` directly, but we need this to enable the `js` -# feature when cross-compiling to WASM. Otherwise, `getrandom` will not build. +# We don't depend on `getrandom` directly, but we need this to enable the +# `wasm_js` feature when cross-compiling to WASM. Otherwise, `getrandom` will +# not build. +# +# Please note that this alone is not enough to make this workaround work. To +# make the selected backend available, `--cfg` flag needs to be passed to rustc. +# We do this in `tools/cross-compiler/src/main.rs`. [target.'cfg(target_arch = "wasm32")'.dependencies.getrandom] version = "0.3.2" features = ["wasm_js"]