Skip to content

Commit

Permalink
Fix invalid ArrayBuffer.prototype.slice() usage (#28212)
Browse files Browse the repository at this point in the history
  • Loading branch information
wrightwriter authored Jul 27, 2023
1 parent 42d77aa commit e893b03
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion files/en-us/web/api/gpubuffer/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ await stagingBuffer.mapAsync(
);

const copyArrayBuffer = stagingBuffer.getMappedRange(0, BUFFER_SIZE);
const data = copyArrayBuffer.slice();
const data = copyArrayBuffer.slice(0);
stagingBuffer.unmap();
console.log(new Float32Array(data));
```
Expand Down

0 comments on commit e893b03

Please sign in to comment.