Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CABsi40JyUq76PSwF%2Bxx_k9CXcJtJmnXEOVXstdQu6BVRoYRc6g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
One of the really rad things about Polymer (0.5) and webcomponents is that everything is just DOM. You can pretty easily use core- and paper- components libraries inside of an (say) angular app to render out content. Doesn't matter if you're using jQuery raw or ember or what have you- DOM is DOM, and it mostly works (modulo some property / attribute bindings)The new localDom API seems to indicate that this may no longer be the case- if I'm redistributing DOM content, I need to use the polymer dom interface, rather than just plain parent/child/append calls on document.This seems to indicate that modern polymer isn't going to be compatible with angular, or with any other library that manipulates the DOM, or is it the case that this only matters when there's more complicated shady/light manipulations?
As an example, if I have content in the drawer part of a paper-drawer-panel, and then, using jquery or some other element selector, inject nodes inside of the already-projected menu div, will this break things? Or is it only the case that I need to use the local DOM api when if I'm changing the nodes that would be selected as content to project (and not their child nodes)?Is there some way to shim the document-level query selectors in there or add a mutation observer that calls distributeContent as needed? I'm guessing it was this shimming and mutation observer that contributed to the slowness of 0.5 in non-chrome browsers.
I've got next week blocked out to actually work on getting angular 1.4 to play nice with polymer 0.9 (we use angular to build the page and manage data, and polymer for handy flexbox directives and material design ui bindings). So I guess I'll figure it out then.
Was there a reason that the built-in versions of the Polymer.dom API couldn't be monkeypatched? In other words, why not make document.querySelector or element.querySelector behave like Polymer.dom's version? Wouldn't this increase interoperability with third party libraries?
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/2ed4c38f-8544-4a29-b79d-aad0ee0c40aa%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CA%2BrMWZhJJtkY_jKm8mSaLavGj3tRSk8Gonka%3DVfgEdD%2BoUaBeQ%40mail.gmail.com.
Hmm, the good news is that just shutting my eyes, going "la la la" and pretending that Polymer.dom doesn't exist seems to work just fine. I built a test angular application that uses paper-drawer-panel, paper-header-panel, and paper-icon-button to add paper-icon-buttons to a list on a timeout using angular's $interval callback to append items to an array and angular's ng-repeat and ng-if directives to manipulate the DOM.My hypothesis here is that I'm only ever really adding new child nodes in the already-distributed DOM elements.
I whipped up a simple bunch of test cases for most of my UI elements here:in the event anyone cares to keep score at home. I'd love someone to point out areas where the Polymer shady DOM is going to bite me in the .. well any place would be a bad place to be bitten. If I can get this working for all of the polymer elements I currently use in production, I'll move forward on it.
eOn Tue, May 19, 2015 at 12:48 PM 'Steve Orvell' via Polymer <polym...@googlegroups.com> wrote:Follow Polymer on Google+: plus.google.com/107187849809354688692We have experimented with patching dom traversal and mutation api's, and there's an experimental import in Polymer that does this. It can let some libraries interoperate more smoothly with Shady DOM powered elements that, for example, perform distribution. We're continuing to work on it and explore if it should be integrated out of the box or be available as an opt in layer.Follow Polymer on Google+: plus.google.com/107187849809354688692On Tue, May 19, 2015 at 6:09 AM, <jim.j...@gmail.com> wrote:Was there a reason that the built-in versions of the Polymer.dom API couldn't be monkeypatched? In other words, why not make document.querySelector or element.querySelector behave like Polymer.dom's version? Wouldn't this increase interoperability with third party libraries?
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/2ed4c38f-8544-4a29-b79d-aad0ee0c40aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CA%2BrMWZhJJtkY_jKm8mSaLavGj3tRSk8Gonka%3DVfgEdD%2BoUaBeQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CABsi40%2Bf2zvKe3annQgqer8Pq06wwLGM3xgFYt7af%2Be5cbDZVw%40mail.gmail.com.
Is the experimental import for avoiding Polymer.dom documented anywhere? I'd be interested in trying it out.
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/65c523d0-47b1-4786-8584-fdd2d2fd8047%40googlegroups.com.
Just wanna make sure...If I build a web-app that targets the Chrome browser, or any browser that will have native Shadow DOM support, can I refrain from using the Polymer.dom APIs, and use native DOM APIs?
On Tuesday, May 19, 2015 at 3:46:20 AM UTC+3, Eric Eslinger wrote:One of the really rad things about Polymer (0.5) and webcomponents is that everything is just DOM. You can pretty easily use core- and paper- components libraries inside of an (say) angular app to render out content. Doesn't matter if you're using jQuery raw or ember or what have you- DOM is DOM, and it mostly works (modulo some property / attribute bindings)The new localDom API seems to indicate that this may no longer be the case- if I'm redistributing DOM content, I need to use the polymer dom interface, rather than just plain parent/child/append calls on document.This seems to indicate that modern polymer isn't going to be compatible with angular, or with any other library that manipulates the DOM, or is it the case that this only matters when there's more complicated shady/light manipulations?As an example, if I have content in the drawer part of a paper-drawer-panel, and then, using jquery or some other element selector, inject nodes inside of the already-projected menu div, will this break things? Or is it only the case that I need to use the local DOM api when if I'm changing the nodes that would be selected as content to project (and not their child nodes)?Is there some way to shim the document-level query selectors in there or add a mutation observer that calls distributeContent as needed? I'm guessing it was this shimming and mutation observer that contributed to the slowness of 0.5 in non-chrome browsers.I've got next week blocked out to actually work on getting angular 1.4 to play nice with polymer 0.9 (we use angular to build the page and manage data, and polymer for handy flexbox directives and material design ui bindings). So I guess I'll figure it out then.e
Follow Polymer on Google+: plus.google.com/107187849809354688692
---
You received this message because you are subscribed to the Google Groups "Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/ac30e4b1-77df-4145-b642-ee20b65bd9af%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CABsi40%2Bf2zvKe3annQgqer8Pq06wwLGM3xgFYt7af%2Be5cbDZVw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/1c7f2a46-ee03-455f-b73f-c5090dc90873%40googlegroups.com.