I'm not at a PC at the moment so I can't comment properly, but this is all totally standard js. In js doing a simple assignment won't copy, using a view and initialising with another will copy, but initialising with view.buffer will re-use the same data.
The views are a convenient way to access data in different ways - for example as uint16
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.
I'm not at a PC at the moment so I can't comment properly, but this is all totally standard js. In js doing a simple assignment won't copy, using a view and initialising with another will copy, but initialising with view.buffer will re-use the same data.
The views are a convenient way to access data in different ways - for example as uint16
Bit more info here: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Typed_arrays