Complementing @Danguilherme's answer follows some important details:
Benefits
There are many benefits to Polymer where we can highlight:
Declarative Programming
Allows you to implement Domain Specific - DSL using powerful, intuitive, meaningful and expressive Markup.
Composition from Minor Components
Building blocks using composition
Maintainability
When you read the code you immediately understand lowering the cost of maintenance. Encapsulation allows you to develop components with a specific function restricting scope and facilitating maintenance.
Real Reusability on the Web
Encapsulation enhances reusability and tool support as Bower allows use by any developer
Extensibility
Implements standard form to extend native elements and custom elements as in the example:
We can implement inheritance in Polymer using:
<polymer-element name="my-car" extends="my-vehicle">
We have the option to override the methods of the Polymer elements and, if necessary, we can use this.super () to call the function of the inherited element.
Scope Separation
Allows differentiated scope for CSS, DOM, and APIs
Interoperability
Integration is done at low level in the DOM so interoperability is complete. It is not necessary to use other JavaScript libraries such as jQuery because we can directly use querySelector, querySelectorAll, getElementById, etc since IE 9 and all other browsers already support this.
Accessibility
Implemented by default.
Productivity
It is obvious when we use it because of these advantages mentioned above.
Testability
The testability of components is provided by the WCT - Web Component Tester
link
Mixins
Mixins serve to add behavior of objects in others. It is a JavaScript feature. Polymer has a utility method to support this feature in the Framework.
Grammar:
Polymer.mixin(target, obj1 [, obj2, ..., objN ])
Exemplo:
var myMixin = {
sharedMethod: function() {
// ...
}
}
<polymer-element name="my-element">
<script>
Polymer(Polymer.mixin({
// my-element prototype
}, myMixin));
</script>
</polymer-element>
Github fonts
Fonts hosted on github can be accessed via Bower
bower install --save Polymer/core-elements
Layout Containers
Several elements to support Layout eliminates the need to use Bootstrap or similar. Allied to Layout Attributes
that works for native elements such as or we have a full set of features for dynamic Layout management.
Theme Support
use to implement Themes for the application
Transition Support
Tags can be used to declaratively transpose content between transitions
Design Tool
Visual tool available as a playground for developing dialogs and application pages using drag-and-drop.