Basically the 'standard' JavaScript way of handling Typed Arrays is horrible (turning them into objects), and I don't really want to implement it - but then I don't want to implement something that's not standards compliant either.
If you want to parse the 'semi-JSON' you get from JSON.stringify with a Uint8Array then (as long as you trust the input!) you can use eval instead...
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
Thanks - yes, this is a bit of a pain... There's a bug open for it here: https://github.com/espruino/Espruino/issues/489
Basically the 'standard' JavaScript way of handling Typed Arrays is horrible (turning them into objects), and I don't really want to implement it - but then I don't want to implement something that's not standards compliant either.
If you want to parse the 'semi-JSON' you get from
JSON.stringify
with a Uint8Array then (as long as you trust the input!) you can useeval
instead...