4 ms·
I never understood why React became so popular. I thought it was a kind of mass hysteria. I was exposed to a broad range of front end frameworks early in my car
by jongjong 4y ago
I never understood why React became so popular.
I thought it was a kind of mass hysteria. I was exposed to a broad range of front end frameworks early in my career (Backbone, SproutCore, JavaScriptMVC/CanJS, AngularJS), one of my colleagues was experimenting with Google's PolymerJS and recommended it. After trying it out, I was blown away by its elegance and simplicity. Yet somehow it never caught on. When React came out, people jumped on the bandwagon en mass; most of them had never even heard of Polymer.
React had some obvious red flags; it seemed unwise to re-render entire components each time and regenerate the DOM instead of trying to work with it; it's a hack. It's not difficult to think of scenarios were it fails; for example think of what happens to an element's scroll bar after it has been re-rendered from scratch; it resets... Yet people kept coming up with workaround after workaround to all these kinds of issues. If they had tried PolymerJS (which was going for a native Web Components approach and interfaced nicely with the DOM instead of bypassing it), they would have questioned React's merits. When the useEffects hook was introduced in React, to me, that was a vindication of Polymer's stance (which it had figured out years earlier) that you couldn't completely pretend that DOM elements don't exist, yet React's solution was not as elegant as Polymer's as it was tacked on as an afterthought rather than as a carefully thought out design decision.
Nowadays, with native Web Components (HTMLElement) in most browsers, I don't see why people would still start projects with React, especially given the massive number of dependencies it typically introduces and how often they keep changing stuff and breaking compatibility.
They promised a simple component library which would be the answer to our prayers. What we got instead is a 7 year religious pilgrimage which involved a million developers simultaneously trying to make sense of it; attempting to discover its true form by inventing abstraction upon abstraction and growing increasingly fanatical as it devolved into a wicked monstrosity which should have brought the wiser among us to our knees, begging for JQuery.
- TheMagicHorsey 4y agoI'm with you on this.
- bsenftner 4y agoI totally agree.
- csm63 4y agoMy favorite comment on this thread, for the last paragraph if nothing else.
- reactus 4y agoFrom the moment I understood the weakness of vanillaJS, it disgusted me. I craved the strength and certainty of unidirectional data flow. I aspired to the purity of Blessed Functional Programming. Your kind cling to fad frameworks and half-baked web components, as though they will not decay and fail you. One day the crude spaghetti code you call an "app" will wither, and you will beg my kind to save you. But I am already saved, for React is immortal...
- Tade0 4y ago> It's not difficult to think of scenarios were it fails; for example think of what happens to an element's scroll bar after it has been re-rendered from scratch; it resets... To this day I can immediately tell that an app was made using React once the first focus/selection bug rears its ugly head.
- mock-possum 4y agoLove to see the Polymer shoutout - Lit, the web component library produced by the Polymer Project, is still my favorite way to organize web components. Nice and simple, provides just enough tools to be useful but mostly stays out of your way, and mostly sticks close to the metal on native web components. I’ve always thought React was some sort of mass hysteria as well.
- strokirk 4y agoI’ve tried Polymer and the web componens, and for a long time it had a really bad accessibility story, and even worse developer experience. It is just google using their size to force bad decisions on the web world again.