Allow unsupporting "js" feature#342
Conversation
|
It's a blatant misuse of the
So I suggest sending fix PRs against the misbehaving libraries. I don't think that introduction of such configuration flag is a good idea. |
|
I understand that this is frustrating, but there is a reason that the Some crates incorrectly enable the Some libraries intentionally enable the Finally, if it turns out getting other libraries fixed is too hard, it is possible to have a (custom or supported) Cosmwasm-only target. Something like However, none of these are changes to |
Some Wasm platforms (e.g. Cosmwasm) do not support bindgen.
On the other hand, a lot of libraries with Wasm support activate the "js" feature.
This PR allows the final crate to set getrandom to
UNSUPPORTED, avoiding this issue.Specifically, it can run
RUSTFLAGS='--cfg js_unsupported' cargo buildetc.