Open mercush opened 2 years ago
So the issue is that the js feature imports and exports a lot of wasm-bindgen specific host functions which cannot be compiled by the NEAR runtime (all symbols prefixed __wbindgen_
).
I suppose the rand utils are meant for convenience for consumers, but this feels like it should be behind a feature flag or have the core utils be in a lower-level lib.
Perhaps the ability to compile to wasm isn't a core use case, and this example will be deprecated?
I am trying to run the tutorial risczero battleship example (available here) but am getting the following error message.
I get this error message shortly after I make my move in the game.
It should be noted that I wasn't initially able to build the example so I made a modification to the code. In the contract/cargo.toml file, I added the dependency
getrandom = { version = "0.2", features = ["js"] }
. This is what I was advised to do here.Please let me know if there is a way to make this work.