Skip to content

Commit e55ef66

Browse files
committed
feat(wasm): add wasm-js feature flag
pass flag to the getrandom crate add feature documentation
1 parent f07c5ef commit e55ef66

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

packages/vorbis_rs/Cargo.toml

+1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ getrandom = { version = "0.3.0", features = ["std"], optional = true }
3333
[features]
3434
default = ["stream-serial-rng"]
3535
stream-serial-rng = ["dep:getrandom"]
36+
wasm-js = ["getrandom?/wasm_js"]
3637

3738
[package.metadata.docs.rs]
3839
rustdoc-args = ["--cfg", "docsrs"]

packages/vorbis_rs/src/lib.rs

+3
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@
2323
//! method, which automatically configures such a builder with suitable random
2424
//! Ogg stream serial numbers. This feature pulls dependencies on random number
2525
//! generation crates.
26+
//! - `wasm-js` Enables the 'wasm_js' feature flag on [getrandom](https://crates.io/crates/getrandom).
27+
//! Used to enable [WebAssembly support](https://docs.rs/getrandom/latest/getrandom/#webassembly-support)
28+
//! for JavaScript environments.
2629
//!
2730
//! # Examples
2831
//!

0 commit comments

Comments
 (0)