New issue
Advanced search Search tips
Starred by 3 users
Status: Fixed
Owner:
Closed: Dec 2015
Cc:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Launch-OWP
Launch-Accessibility: ----
Launch-Legal: ----
Launch-M-Approved: ----
Launch-M-Target: ----
Launch-Privacy: ----
Launch-Security: ----
Launch-Status: ----
Launch-Test: ----
Launch-UI: ----
Product-Review: ----

Blocked on:
issue 43394



Sign in to add a comment
Move DOM attributes to prototype chains.
Project Member Reported by yukishiino@chromium.org, Apr 13 2015 Back to list
Change description:
Blink has placed DOM attributes on instances instead of prototypes. However, the Web IDL spec requires that DOM attributes must be placed on prototype chains (except for a few exceptions such as static attributes and [Unforgeable].) We move DOM attributes on instances to prototype chains following the spec.

Changes to API surface:
Typical issues that web developers would face to are as follows, but not limited to.
- JSON.stringify(domObject)
  returns {}, which was {domAttr1: value1, domAttr2, value2, ...}
- "use strict"; domObject.readonlyAttr = anyValue
  throws an exception.  Before, just ignored.
- domObject.hasOwnProperty("feature1")
  returns false even if feature1 is supported.
  ("feature1" in domObject) is the correct way.

Links:
Public standards discussion:
https://heycam.github.io/webidl/#es-attributes

Support in other browsers:
Internet Explorer: supported
Firefox: supported
Safari: not supported

 
Cc: rbyers@chromium.org
Detailed work is tracked here:
https://code.google.com/p/chromium/issues/detail?id=43394

Comment 2 by rbyers@chromium.org, Apr 13 2015
Blockedon: chromium:43394
(Using "blocked-on" to track the two-way relationship)
Status: Fixed
Sign in to add a comment