First, thanks for the cool crate. I have been enjoying experimenting with it in a few of my projects.
An issue I came across is that depending on other project dependencies, using the wasm-bindgen = { version = "0.2", features = ["serde-serialize"] } can cause a "cyclic package dependency" and prevent the project from building (the getrandom crate ends up depending on itself). I did some research on this issue in the Rust Wasm context, and this can be caused by using that serde-deserialize feature of wasm-bindgen. Removing that feature and instead using the serde-wasm-bindgen crate in its place resolves this issue. Making this update on a local branch let my project compile and run without issue. I also tested the leptos-leaflet project examples with this change, and they also seem to run just fine.
Here is some discussion on this issue that helped me resolve it:
rustwasm/wasm-bindgen/pull/3031
tkaitchuck/aHash/issues/95
I make this issue as the update is not strictly required, but it can lead to a bit of confusion as it comes up depending on the other project dependencies without too much help from the standard Cargo error messages.
I can make a pull request correcting the Cargo.toml for the main library if that would be helpful. Otherwise, anyone else who comes across this issue can make the update locally or in a fork and resolve the issue that way. Thank you again.
Hi all,
First, thanks for the cool crate. I have been enjoying experimenting with it in a few of my projects.
An issue I came across is that depending on other project dependencies, using the
wasm-bindgen = { version = "0.2", features = ["serde-serialize"] }
can cause a "cyclic package dependency" and prevent the project from building (thegetrandom
crate ends up depending on itself). I did some research on this issue in the Rust Wasm context, and this can be caused by using thatserde-deserialize
feature ofwasm-bindgen
. Removing that feature and instead using theserde-wasm-bindgen
crate in its place resolves this issue. Making this update on a local branch let my project compile and run without issue. I also tested theleptos-leaflet
project examples with this change, and they also seem to run just fine.Here is some discussion on this issue that helped me resolve it:
I make this issue as the update is not strictly required, but it can lead to a bit of confusion as it comes up depending on the other project dependencies without too much help from the standard Cargo error messages.
I can make a pull request correcting the
Cargo.toml
for the main library if that would be helpful. Otherwise, anyone else who comes across this issue can make the update locally or in a fork and resolve the issue that way. Thank you again.