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月.
Object.isExtensible() メソッドは、オブジェクトが拡張可能であるか(新しいプロパティを追加することができるかどうか)を判定します。
チェックするオブジェクトです。
論理値で、与えられたオブジェクトが拡張可能であるかどうかを示します。
オブジェクトは既定では拡張可能です。つまり、新しいプロパティの追加が可能であり、 [[Prototype]] プロパティに再代入することができます。オブジェクトは Object.preventExtensions(), Object.seal(), Object.freeze(), Reflect.preventExtensions() のいずれかを用いる事で拡張不能に設定する事が可能です。
ES5 では、このメソッドの引数がオブジェクトではない場合(プリミティブの場合)、 TypeError が発生します。 ES2015 以降では、オブジェクトでない引数は、それが拡張不可能な通常のオブジェクトであるかのように扱われ、単に false を返します。
| ECMAScript® 2027 Language Specification # sec-object.isextensible |
Enable JavaScript to view this browser compatibility table.
This page was last modified on 2025年8月23日 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.