var proto = Object.create(HTMLElement.prototype);
proto.createdCallback = function () { this.customAttributes = {}; console.log('created');};
proto.attachedCallback = function() { console.log('attached');};
proto.bind = function(name, value, oneTime) { console.log('bind', name, value, oneTime);};
proto.setAttribute = function(name, value) { console.log('setAttribute', name, value);};
proto.attributeChangedCallback = function(attrName, oldVal, newVal) { console.log('attribute changed', attrName, oldVal, newVal);};
Object.defineProperty(proto, 'something', { get: function () { return this.customAttributes['something']; }, set: function (val) { this.customAttributes['something'] = value; console.log('something change', value); }});
document.registerElement('dx-test', { prototype: proto });<dx-test something="{{someProperty}}"></dx-test>
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.
For more options, visit https://groups.google.com/groups/opt_out.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CAMsr9Pnam_Wz%2BgZ69PdN4WhxKFVG8pJFX7YWkEgNFs5YydJyZQ%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CABMdHiTn3E3rFieatn%3DCRGXKwSBiCH27uz7_J9YNcG6GHMWt2A%40mail.gmail.com.
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/70e68a23-a5aa-4b1a-8b7e-48de9604325a%40googlegroups.com.
Platform builds are available via bower (bower install Polymer/platform), git (git clone git://github.com/Polymer/platform), and cdnjs ( http://cdnjs.com/libraries/polymer/)
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CAMsr9PkDZTJgfL-Yp7HrPNKCOtNQNuY9a22-Z3M53VdVGKmawA%40mail.gmail.com.
Rob,I asked a similar question about the "necessity" of the Shadow DOM a few months ago - https://groups.google.com/forum/?fromgroups=#!topic/polymer-dev/oVWSsMhFDnc. Basic upshot was although the polyfills themselves don't have a dependency on the Shadow DOM, Polymer depends on it, and it will be used if you use platform.js as well, even if you are only planning on using part of the platform like custom elements.If you are looking for simple, non-shadow DOM pre-built library, x-tags is maybe the way to go (although from my experience, the x-tag community is way less active). It is the biggest issue we have with Polymer - the shadow DOM polyfill is a bit invasive, and degrades performance - in our case, polymer doubles the time to load a page compared to x-tags. We have decided we will need to try "re-package" parts of the Polymer platform in our own library to get the performance characteristics we require, which is a shame, because I really like the library and the layer of sugar it provides.Regards,Ian
You received this message because you are subscribed to a topic in the Google Groups "Polymer" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/polymer-dev/puRMCV1-8nI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to polymer-dev...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CAHbmOLZxfQq4yDfnPUtuXY%3DvL2h3N3ckKFfuqbw%2BPHkvb7O_5A%40mail.gmail.com.
These videos are great Scott. Very helpful. Rob and I talked about shortening them a bit and overlaying some commentary.
If people are interested in building + using a single .min.js file for a polyfill, it's basically the same procedure. Instead of enumerating the sources for the polyfill, install the node modules and build with Grunt. Example building the Custom Elements polyfill:
bower install Polymer/CustomElements
cd bower_components/CustomElements
npm install
grunt
...gets you custom-elements.min.js
To view this discussion on the web visit https://groups.google.com/d/msgid/polymer-dev/CAMsr9Pm2FAycLjknWzuLLmEkMyveKhrz6YJnws0u-y7AdzH3AA%40mail.gmail.com.