Are there predefined templates for global settings / status for components?

I currently have a component like this:

<polymer-element name="my-widget" constructor="MyWidget"> <script> Polymer('my-widget', {}); MyWidget.someGlobalConfigValue = 1234; </script> </polymer-element> 

Are there other approaches to this that I should consider?

(aside: it would be neat if Polymer() returned the constructor, so I don't need to force the name)

+7
polymer
source share
1 answer

One template is to use the component for configuration: http://www.polymer-project.org/docs/polymer/polymer.html#global

+7
source share

All Articles