Have code which generates an https://rustwasm.github.io/wasm-bindgen/api/web_sys/struct.CustomEvent.html.
Logging event.detail()
results in: {index: 1}
. This is of type JsValue
, but how to obtain the integer 1 value in rust?
One way could be https://rustwasm.github.io/docs/wasm-bindgen/reference/iterating-over-js-values.html Other betters ways?