-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't target Wasm web #6
Comments
For For us, we might be able to work around by not doing the Lines 7 to 12 in b861297
If we use an empty string there, it will just fall back to random bytes: Lines 14 to 21 in b861297
Can you try |
it's a deeper features in
to reproduce No worry if there's no-way to make it work(i know the pain), nothing urgent; thx for your time 🙏 |
You can add the following to your # `getrandom` is a dependency of `rand` which is in turn a dependency of `xid`.
# Enable `js` feature to support `wasm32-unknown-unknown` target used by `wasm-pack`.
# Makes `getrandom` assume that you are building for an environment containing JavaScript.
# See https://docs.rs/getrandom/latest/getrandom/#webassembly-support
getrandom = { version = "0.2.7", features = ["js"] } |
Seem to build fine now 🙏 but somehow it didn't get any generated response when i try to call it from js. 🤔 Anyway incase it's build fine, i'll close this for now and i will take a look at this again when I have some free time. Thank! |
It builds fine but the wasm crashes on web. |
when
throw
which
not sure this can be fix or any workaround?
The text was updated successfully, but these errors were encountered: