Closed
Bug 1026607
Opened 10 years ago
Closed 6 years ago
Crash when using custom element inside of another custom element
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
RESOLVED
INCOMPLETE
People
(Reporter: jlal, Unassigned)
References
(Blocks 1 open bug)
Details
STR (sitting across from wchen now but here for record keeping): Use my gaia branch: https://github.com/lightsofapollo/gaia/tree/terrible-crash-fun Open gaia/shared/elements/gaia_grid/examples/index.html (relative to to the gaia checkout) Click the "Another Webapp" icon <crash should happen>
Updated•10 years ago
|
Blocks: webcomponents
Reporter | ||
Comment 1•10 years ago
|
||
Using .createElement for the additional custom element seems to cause the crash using innerHTML on another element (that is not in the dom) seems to help: ``` var wrapper = document.createElement('div'); wrapper.innerHTML = '<gaia-confirm id="confirm-message">' + '<h1 id="confirmation-message-title"></h1>' + '<p id="confirmation-message-body"></p>' + '<gaia-buttons skin="dark">' + '<button class="cancel" id="confirmation-message-cancel" type="button"></button>' + '<button class="confirm" id="confirmation-message-ok" type="button"></button>' + '</gaia-buttons>' + '</gaia-confirm>' var element = wrapper.firstElementChild; ``` My work around
I can't reproduce this based on the checkout, your branch and dom.webcomponents.enabled set to true using 37.0a2 (2015-01-24). I'm not sure the page is running correctly, however. The "A Webapp" and "Another Webapp" are large white rectangles and clicking on "Another Webapp" does nothing except print "show cancel~>~>~" to the console. Although there's no crash, I suspect something isn't working correctly, nonetheless. (Incidentally, I've had experiences with the browser version above not showing web components within web components and crashing on complex apps, too. But this is with apps built with Polymer and the missing inner web components and crashes only occur when the above config is set to true.)
Comment 3•6 years ago
|
||
no proper testcase -> INCOMPLETE
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•