Closed Bug 1119745 Opened 10 years ago Closed 10 years ago

Custom element, created with document.registerElement has no prototype

Categories

(Core :: DOM: Core & HTML, defect)

36 Branch
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1081037

People

(Reporter: kecskes.adam, Unassigned)

References

()

Details

(Whiteboard: DUPEME)

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:36.0) Gecko/20100101 Firefox/36.0 Build ID: 20150108004006 Steps to reproduce: I've enabled dom.webcomponents.enabled, and then tried to run this code: var foo = document.registerElement('x-foo', { prototype: Object.create(HTMLElement.prototype) }); // undefined in Firefox console.log(foo.prototype); Actual results: For some reason, foo.prototype is undefined. Expected results: The custom element should have a prototype, like HTMLElement. It works in chrome, or with the webcomponent.js fallback.
This works on Nightly (38). I imagine it's been fixed elsewhere, just not sure where.
Component: Untriaged → DOM
OS: Windows 7 → All
Product: Firefox → Core
Hardware: x86_64 → All
Whiteboard: DUPEME
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.