-
Notifications
You must be signed in to change notification settings - Fork 150
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Initialization might fail when surrounded by p-element #116
Comments
It almost looks like a browser bug. |
It does look like indeed. But isn't: if you try your example (and wrap it with FYI, my system: OS-X 10.10.2 |
and, what makes it even more weird: it depends on what type of child-element is within: not all fail... |
my best bet would be not to see it as a bug that has to be repaired, but to find a way to be able to read the innercontent, even in these situations. |
sorry, not mentioned right: it sure looks like a browser-bug of coarse. |
I see this as a huge problem. Because we cannot predict how/where users are going to place the custom elements. I like the principle of being able to write html-markup inside a custom-element which will be processed. The only predictable way (and workable, though less than it was before), is by allowing only I'm considering to use this principle for our custom elements. Related to <p>
<x-flipbox><!--
<div><h1>Front</h1></div>
<div><h1>Back</h1></div>
--> </x-flipbox>
</p> We use a html-parser to create nodes from a string, thus we can transform the content of the |
I also posted the issue at Polymer: Polymer/polymer#1180 (comment) So we know what makes it happen: it's up to x-tag if/how to deal with it. I'll close the issue. |
This is a strange issue that we've encountered during development of our own custom elements (non x-tags, sorry).
Yet, it also seems to hit the x-tags - from a quick investigation.
The issue seems to be:
Whenever a customelement is wrapped inside a
p-element
, the dom seems to do a miscalculation on some child-elements. That is: some childNodes might be missing.The effect can be seen at the flipbox-demo, when you wrap both
flipboxes
inside ap
-element. The result is that the first still works, but the second doesn't. It has to do with the presents of thediv
-element - as far as i can see.I made a small jsbin to show when the dom fails to see some child-elements --> look at the console to find out that the 3th element seems to be empty.
Even though i'm not using x-tags, it would be great if you guys know what's going on and find a solution.
Thx,
Marco Asbreuk
The text was updated successfully, but these errors were encountered: