Get to know MDN better
このページはコミュニティーの尽力で英語から翻訳されました。MDN Web Docs コミュニティーについてもっと知り、仲間になるにはこちらから。
This feature is well established and works across many devices and browser versions. It’s been available across browsers since 2015年7月.
byteLength は TypedArray のアクセサープロパティで、この型付き配列の長さを(バイト単位で)返します。
byteLength プロパティはアクセサープロパティであり、その設定アクセサー関数は undefined です。つまり、このプロパティは読み取り専用です。型付き配列が長さ追跡である場合、その長さは基盤となるバッファーの長さに依存し、バッファのサイズ変更時に変更されることがあります。そうでない場合、値は型付き配列の構築時に確定され、変更できません。長さ追跡の有無にかかわらず、基盤となるバッファーのサイズ変更により表示範囲ができなくなった場合、byteLength は 0 になります。
| ECMAScript® 2027 Language Specification # sec-get-%typedarray%.prototype.bytelength |
Enable JavaScript to view this browser compatibility table.
This page was last modified on 2026年1月22日 by MDN contributors.
Your blueprint for a better internet.
Visit Mozilla Corporation’s not-for-profit parent, the Mozilla Foundation.
Portions of this content are ©1998–2026 by individual mozilla.org contributors. Content available under a Creative Commons license.