javascript 属性 像“__proto__”这样的名字在 ES5/6 中没有标准化吗?
Are javascript property names like "__proto__" not standardized in ES5/6?
js starts/ends 中有一些属性带有双下划线,例如 __proto__
。但我知道它等于 constructor.prototype,对吧?我想知道 ES5/ES6 标准是否包含这些 xxx_ 属性 名称,或者它们只是特定于实现的关键字,在不同的实现中可能有不同的行为?
另外:我在哪里可以检查关键字是否是 ES 标准的一部分?
I know it equals to constructor.prototype, right?
No.
I wish to know whether ES5/ES6 standard included these __xxx__
property names, or they're just implementation specific keywords, might have different behavior in different implementations?
你可以在MDN documentation里找到概览,有__count__
、__noSuchMethod__
、__parent__
、__proto__
、__defineGetter__
、 __defineSetter__
、__lookupGetter__
和 __lookupSetter__
; 所有这些都已弃用。 Gecko 以外的其他实现可能具有更多功能。
只有 getter/setter 方法和 __proto__
在实现中是常见的,只有 .
where can I check if a keyword is part of ES stardard, any recommended web-sites?
刚刚阅读 the standards themselves!
js starts/ends 中有一些属性带有双下划线,例如 __proto__
。但我知道它等于 constructor.prototype,对吧?我想知道 ES5/ES6 标准是否包含这些 xxx_ 属性 名称,或者它们只是特定于实现的关键字,在不同的实现中可能有不同的行为?
另外:我在哪里可以检查关键字是否是 ES 标准的一部分?
I know it equals to constructor.prototype, right?
No.
I wish to know whether ES5/ES6 standard included these
__xxx__
property names, or they're just implementation specific keywords, might have different behavior in different implementations?
你可以在MDN documentation里找到概览,有__count__
、__noSuchMethod__
、__parent__
、__proto__
、__defineGetter__
、 __defineSetter__
、__lookupGetter__
和 __lookupSetter__
; 所有这些都已弃用。 Gecko 以外的其他实现可能具有更多功能。
只有 getter/setter 方法和 __proto__
在实现中是常见的,只有
where can I check if a keyword is part of ES stardard, any recommended web-sites?
刚刚阅读 the standards themselves!