Web Components with Mozilla’s Brick and X-Tag(hacks.mozilla.org)
hacks.mozilla.org
Web Components with Mozilla’s Brick and X-Tag
https://hacks.mozilla.org/2014/03/custom-elements-for-custom-applications-web-components-with-mozillas-brick-and-x-tag/
5 comments
Can you explain why it feels heavy? I would love to know more.
Polymer's entire stack is a la carte:
* platform.js - polyfills if you just want to use vanilla web component apis, today
* polymer.js - build declarative custom elements that use data-binding, touch, property observation, inheritance
* elements (ui/non-ui) - if you don't want to write any code at all :)
Sugaring libraries like Brick and Polymer that sit on top of the native web component APIs will, of course, be opinionated and do things a bit differently. However, the workflow for consuming components will be similar across the board. Something like `bower install brick-carousel polymer-tabs`. Then use the elements in your pages.
Polymer's entire stack is a la carte:
* platform.js - polyfills if you just want to use vanilla web component apis, today
* polymer.js - build declarative custom elements that use data-binding, touch, property observation, inheritance
* elements (ui/non-ui) - if you don't want to write any code at all :)
Sugaring libraries like Brick and Polymer that sit on top of the native web component APIs will, of course, be opinionated and do things a bit differently. However, the workflow for consuming components will be similar across the board. Something like `bower install brick-carousel polymer-tabs`. Then use the elements in your pages.
The Polymer project from Google is something I've been following and I feel like it holds a lot of potential... Why hasn't it gained traction? Web components seem to be a great vision of the future of web design/development.
How does this compare with the Polymer project?
X-Tag leverages the joint polyfill Google is the general maintainer of (Mozilla contribute code to it). It's the same one at the base of the Polymer stack.
Polymer, in comparison to Brick has a much more ambitious approach to being the framework to build apps with instead of aiding the creation of apps. Comparable with Dojo or .NET instead of jQuery.
Polymer, in comparison to Brick has a much more ambitious approach to being the framework to build apps with instead of aiding the creation of apps. Comparable with Dojo or .NET instead of jQuery.
I don't think that's really true about Polymer. It's still just a framework for creating custom elements. What features are you thinking of to compare to Dojo?
The big difference that I see is the template binding portion of Polymer which allows you to define an elements markup with data-binding template sort of like Angular.
The big difference that I see is the template binding portion of Polymer which allows you to define an elements markup with data-binding template sort of like Angular.
Yes, very true. I was a bit fast answering this earlier. So far, there are no data-bindings in Brick.
Also see intern presentation from Leo last summer.
https://air.mozilla.org/intern-presentations-zhang/
The code samples and component lifecycle remind me of reactjs (by Facebook). Can anyone comment on similarities and differences?
I don't see any mention of browser support?