Include stdweb only on wasm32 target

I want a Cargo.toml to include stdweb if and only if the target is wasm32.

From googling, I have:


[target.'cfg(target_arch = "wasm32")'.dependencies]
stdweb = "0.4.20"

However, from compiling, it seems that stdweb is being pulled in even when for x86 linux

Are you sure you don't have a duplicate stdweb = ... entry on [dependencies] section?

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.