Does ES6 make JavaScript frameworks obsolete?
stackoverflow.blog
stackoverflow.blog
I also just don't see how any of the ES6 features named in the article negate the need for a framework like React. React et al. are built on the DOM API more than any individual language feature.
All in all this article feels very confused.
I expected at least a modicum of quality from an official StackOverflow post, but it's so wrong in so many levels that I can only but flag it.
Even aside from ES6 not being new, the description of what is good and bad about each side are just... not correct. JS coders don't ebb and flow back and forth to frameworks. Frameworks are not niches of coders fighting for their usage in a wider community. The only thing this author got right is that much of ES6 is syntactic sugar.
Of course, that is the exact reason that babel was needed, but as browsers adopt support of ES6, that need diminishes. Put that together with HTTP/2 and there is an argument that our bundling habits and toolchains could be simplified, but that is orthogonal to whether or not we use frameworks.
Frameworks are quite sensible things to use in a large variety of situations. If you're building a large enterprise application, a framework can provide a lot of stability, a large ecosystem and resources that rolling your own can't provide.
And it's not a killer of other frameworks, either. ES6 doesn't give me the wings I need to ditch Winston for logging or Redux for managing state. Not sure how this article got to the front page, but it certainly shouldn't stay here :P
I’d like to point out that frameworks exist in languages more mature and complex than ES6. So I don’t know what it is that javascript people think only they can see and everyone else doesn’t, after only 5 years or so of having a barely usable programming language.
Can you imagine someone claiming it's wrong to use a framework like ASP.NET or Entity Framework instead of "vanilla dotnet"? Or that it's wrong to use Laravel instead of "vanilla PHP"? Or Spring instead of "vanilla Java"?
The only real valid point is bloat, simply because the web is the only platform that still has a code size requirement of applications from the 80s. It's not that there is no solution for it. Take for example island architecture, there is no such thing in "the platform". So if you do care about bloat and want to load only part of the app that's used, you would use a library, or framework, whatever you call it to help implement that. "write more compact code" or "avoid writing code" sounds like giving up to arbitrary restrictions to me.
Performance isssues are mostly caused by incompetece, using frameworks or otherwise. The rest of the issues can be attributed to anything, and is subjected to improvements, rather than to be seen as reasons to dismiss the whole idea of frameworks.
I'd like to point out another thing, all the tiny, low quality, "unixy" garbage on npm actually exists because of the dogmatic avoidance of frameworks.
what you need to consider is what qualifies for being in the language in the first place. Having a small core lets JS be usable in all sorts of contexts, like embedded devices and "stored procedures" of auth and database systems. every thing you add is irreversible and globally piles on requirements to everywhere JS is used.
the solution you ACTUALLY need to solve the OP's question is to add to the DOM/Browser APIs, not to JavaScript. Aka, web components (which have their own problems but i dont have the energy to get into right now)
I'd like to see more authorization/authentication baked in at some point, data tables and manipulation would be great too.
New browser APIs do remove the need for libs for DOM manipulation, date, time, and price formatting, etc.
ES6 makes many things so much nicer to write.
But beyond those primitives, there's little there to replace a framework.
I'd also like to know how they imagine rendering complex DOM structures. It's still a nightmare to do with just Javascript. Without at least Preact or Vue, as the smallest options, it's just tedious and complex.
The alternative to building a complex stack of components in your framework is to build the thing you want in vanilla JS (exactly as you would with plain ES6) and then call it using a hook. The maintenance overhead for complicated things that don't integrate in to the framework well will be exactly the same, but you also get to use the framework for things that do integrate well.
So no, ES6 isn't going to replace anything. It will augment framework use in some edge cases with high complexity. That's exactly how things work now.
The problem with the article is that the author thinks overcoming the difficulty in building a complex application is a matter of writing better code. That is wrong. The way to build a complex application is to be more organised. That's what frameworks make easier, even if the code ends up being pretty horrible.
I'm just a beginner developer, and I would actually prefer vanilla ES6, but I can picture wildly different ways of doing things with ES6 between each company. So then each company has their own abstractions, libraries and conventions (aka a framework, but localized). Then I imagine documentation about the structure, to get new devs up to speed.
When the girlfriend had to switch to Angular from React at her junior position, it took her a while to get comfortable with the codebase. Not sure how much that matters amongst experienced developers.
There are no performance issues with ember.js glimmer engine, large payload argument is also old and wrong for big apps, among other wrong claims in a single sentence.
I will not argue with anyone here below on hacker news. If you reply to my comment chances are I might not respond back. I just skimmed the article and saw this part, made me realize I shouldn’t read this article further.