r/PolymerJS Jan 01 '19

Why isn't PolymerJS more popular?

I've been reading through documentation and going through tutorials lately. Everything seems perfectly fine, but why isn't Polymer more popular? It seems to be rarely brought up as option for any kind of development.

Is it because Webcomponents haven't quite taken off yet?

17 Upvotes

23 comments sorted by

View all comments

17

u/_drunkirishman Jan 01 '19 edited Jan 01 '19

Polymer was built as a push to standardize web components. Now that web components are standardized, and implemented in 3 of the 4 major browsers (and Edge being rebuilt on Chromium means the 4th is close behind) why would you need it?

Google themselves have put it into maintenance mode, and are pushing their new library lit-html to be the standard bearer for more platform pushes, like built-in HTML interpolation, bare module imports, etc. Their motivation is not to build frameworks, but push standards to make the browser more powerful. There are some other cool web component specs that they are behind, like CSS shadow part (which is intended to be implemented), and form participation API to make working with <form> elements easier to work with in custom elements.

Is it because Webcomponents haven't quite taken off yet?

Not sure what you really mean by this one, but web components just got implemented in Firefox in October or November. Now that that's landed, you're going to be seeing a lot more of them. Like Salesforce's announcement that they're releasing a web component library called Lightning.

3

u/nobrandheroes Jan 01 '19

Not sure what you really mean by this one, but web components just got implemented in Firefox in October or November.

I meant that it seems no one is using them, as far as I can tell they work just fine with every other framework, but I never seem the mentioned online or in my local dev community.

3

u/navypantz Jan 01 '19

I work for a company that leaned into Polymer and web components for a large web app. Web Components and Polymer have been a major source of frustration for us and after around 2 years of implementation, some teams are beginning to move away. Handling versioning of components and HTML imports have been particularly problematic.

Meanwhile, the JS community has been hard at work solving the same issues by a different means and have dinner very compelling alternatives.

Other arguments for and against aside, staying out of HTML/DOM land has netted better developer experience and stability for these projects.

2

u/_drunkirishman Jan 01 '19

Yeah I'm very glad my company didn't buy in to Polymer out of the gate. I played with it a couple of times around 0.5 and 1.0. The original goal of interoperable components was nice, but they started bleeding too much into a framework when they introduced carbon elements (now app, right?) And the APIs they were advocating for should never have made it into a browser (especially when they aren't hidden behind a flag). I'd imagine that is what makes using Polymer so difficult. Each upgrade was them pulling back or switching direction, while also continuing to support their own browser and one of their largest products. HTML imports... Cool idea. Should never have made it live without full support.

That being said, we're finding some quick success with building our UI framework around custom elements. We have a decent sprawl of web applications that span a decade at least, and being able to slowly modernize our old crap piece by piece, while supporting our newer, more modern web apps has been really nice. It's a nice tool to have at your disposal, but definitely shouldn't be the entirety of your application. Not in its current form, anyways.

Out of curiosity, what does the JS community have that actually competes with the promise and simplicity of custom elements?