ArrayBufferView#length missing
See original GitHub issueThe TypedArray
documentation (https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypedArray) shows there is a TypedArray#length
member that indicates the number of elements in the array.
ArrayBufferView
is an alias for TypedArray
(https://developer.mozilla.org/en-US/docs/Web/API/ArrayBufferView). Therefore, it should also have a length
property. However, the tslib ArrayBufferView
interface does not have it:
Issue Analytics
- State:
- Created 3 years ago
- Comments:6
Top Results From Across the Web
ArrayBuffer has no data when using the incoming data
JavaScript's ArrayBuffer has one constructor which takes the size , in bytes, of the array buffer to create. Try new ArrayBuffer(msg.data.length); ...
Read more >ArrayBuffer.prototype.byteLength - JavaScript - MDN Web Docs
The byteLength accessor property represents the length of an ArrayBuffer in bytes.
Read more >RangeError: invalid array length - JavaScript
The length property of an Array or an ArrayBuffer is represented with an unsigned 32-bit integer, that can only store values which are...
Read more >Typed arrays - Binary data in the browser - web.dev
To use Typed Arrays, you need to create an ArrayBuffer and a view to it. The easiest way is to create a typed...
Read more >ArrayBuffer, binary arrays - The Modern JavaScript Tutorial
The basic binary object is ArrayBuffer – a reference to a fixed-length contiguous memory area. We create it like this:.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yes, including
DataView
which does not have that property. Look closely at theArrayBufferView
link you posted to MDN. The last item on the list isDataView
.ArrayBufferView
represents aTypedArray
. ADataView
is a typed array.That sounds like a userland thing, not a tslib provided type. As the MDN states, there is no interface or constructor called TypedArray, so i wouldn’t expect this library to provide one.