Skip to content
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

Update es6 & beyond - Chapter 5: Collections - TypedArray constructor description #1325

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sJJdGG
Copy link

@sJJdGG sJJdGG commented Jul 28, 2018

As mentioned in MDN and other sources TypedArray(length) constructor makes a view of length elements not bytes.
It can be also tested by:

var x = new Uint32Array(2);
console.log(x.length) // 2
console.log(x.byteLength) // 8
x[1] = 25;
console.log(x[1]); // 25

As mentioned in MDN and other sources TypedArray(length) constructor makes a view of `length` elements not bytes.
It can be also tested by:
```javascript
var x = new Uint32Array(2);
console.log(x.length); //2
x[1] = 25;
console.log(x[1]); //25
@sJJdGG sJJdGG changed the title Update ch5.md Update es6 & beyond - Chapter 5: Collections - TypedArray constructor description Jul 28, 2018
@getify getify force-pushed the master branch 6 times, most recently from 5cb284a to 8af48e2 Compare August 28, 2019 12:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants