-
Notifications
You must be signed in to change notification settings - Fork 2k
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
0.8 patching #1462
0.8 patching #1462
Conversation
…fore, removeChild
if (this.node.nodeType === Node.TEXT_NODE) { | ||
return this.node.textContent; | ||
} else { | ||
return Array.prototype.map.call(this.childNodes, function(c) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this.childNodes
-> Polymer.dom(this).childNodes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The calling context is Polymer.dom, so this is correct.
@@ -349,6 +350,13 @@ | |||
var nativeRemoveChild = Element.prototype.removeChild; | |||
|
|||
function insertBefore(parentNode, newChild, refChild) { | |||
if (newChild.nodeType === Node.DOCUMENT_FRAGMENT_NODE) { | |||
console.log(parentNode, newChild, refChild); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove logging
@kevinpschaaf PTAL |
LGTM |
Adds additional accessors to Polymer.dom: first/last child/ElementChild, previous/next sibling/ElementSibling, textContent, innerHTML
Adds experimental
patch-dom.html
import which patches dom that interacts with Shady DOM such that normal dom tree traversal and mutation api's can be used. This can enhance interoperation with 3rd party code that is not aware of Polymer.dom.