<story><title>ES6 in Depth: Destructuring</title><url>https://hacks.mozilla.org/2015/05/es6-in-depth-destructuring/</url></story><parent_chain><item><author>bakhy</author><text>No offense meant to anyone, but I really do not like this constant stream of new features in JavaScript. There are some core issues with the language which, of course, cannot be just fixed, and no new features will make them go away. But there is also a beautiful simplicity and power in the way this (used to be) funny little language does classes, objects, scoping... I feel like these new features are bloating it, and for what? So that you can write an assignment in 1 instead of 3 lines? Wow. It&amp;#x27;s as if, whatever programming language is trendy, JavaScript must absorb as much of its features as it can...&lt;p&gt;Don&amp;#x27;t get me wrong, destructuring is a nifty feature, but it&amp;#x27;s not really necessary. Plus, things like that usually get thought through along with everything else, when the language is designed. Not only is this increasing the conceptual weight of the language (OK, maybe I exaggerate in this example ;) but there are many more features added all the time), but now you also have a new set of potential pitfalls when doing potentially type-inappropriate destructuring. (I see from the text that you sometimes get undefined, and sometimes a TypeError?) Does JS need more of that?&lt;p&gt;Why not keep it simple? It may have its flaws, but the JavaScript mental model, once you figure out some corner cases, is really simple and powerful. I find it sometimes very elegant. This feature bloat reduces that, IMO, and could hurt understandability of JS code.</text></item></parent_chain><comment><author>jeswin</author><text>I down voted you, I owe you an explanation.&lt;p&gt;&amp;gt; I really do not like this constant stream of new features in JavaScript&lt;p&gt;ES6&amp;#x2F;Ecmascript Harmony was announced seven years back, and has been actively discussed for the last four years. So the constant stream of new features you see are JS engines implementing parts of the standard, which is now in its final shape. ES-Discuss mailing lists* are open for community participation (like someone mentioned below) and is led by people with a lot of experience in their respective focus areas. Every new feature has had to pass through many levels of debates, and have (mostly) been borrowed after being found successful either in other languages or libraries.&lt;p&gt;&amp;gt;  I feel like these new features are bloating it, and for what?&lt;p&gt;De-structuring is fairly easy to grasp, and is not even one of the main draws in ES6. Since the last changes to JS, the environment and therefore expectations have changed a lot: (a) JavaScript is now a server-side technology in a big way, (b) async has become increasingly important, (c) people are writing very complex apps in JS. Without the changes in ES6 (and ES7&amp;#x2F;8 going forward), developers would have hated working with JS and JavaScript could have slowly died.&lt;p&gt;If you have been following, you&amp;#x27;d notice that JS has a very vibrant community around it. One big reason for that is that they see the language evolving with the technology that surrounds it. Finally, note that all the new enhancements have come without breaking backward compatibility.&lt;p&gt;* I lurk there, not a contributor. Have learnt a ton from just subscribing to it.</text></comment>
<story><title>ES6 in Depth: Destructuring</title><url>https://hacks.mozilla.org/2015/05/es6-in-depth-destructuring/</url></story><parent_chain><item><author>bakhy</author><text>No offense meant to anyone, but I really do not like this constant stream of new features in JavaScript. There are some core issues with the language which, of course, cannot be just fixed, and no new features will make them go away. But there is also a beautiful simplicity and power in the way this (used to be) funny little language does classes, objects, scoping... I feel like these new features are bloating it, and for what? So that you can write an assignment in 1 instead of 3 lines? Wow. It&amp;#x27;s as if, whatever programming language is trendy, JavaScript must absorb as much of its features as it can...&lt;p&gt;Don&amp;#x27;t get me wrong, destructuring is a nifty feature, but it&amp;#x27;s not really necessary. Plus, things like that usually get thought through along with everything else, when the language is designed. Not only is this increasing the conceptual weight of the language (OK, maybe I exaggerate in this example ;) but there are many more features added all the time), but now you also have a new set of potential pitfalls when doing potentially type-inappropriate destructuring. (I see from the text that you sometimes get undefined, and sometimes a TypeError?) Does JS need more of that?&lt;p&gt;Why not keep it simple? It may have its flaws, but the JavaScript mental model, once you figure out some corner cases, is really simple and powerful. I find it sometimes very elegant. This feature bloat reduces that, IMO, and could hurt understandability of JS code.</text></item></parent_chain><comment><author>solarexplorer</author><text>ES6 may make the language itself more complex, but I would argue that it does make your code simpler and more concise. Destructuring and arrow functions may seem gimmicks, but they do reduce the visual complexity of the source code and allow you to concentrate on more important things.&lt;p&gt;And stuff like the module system, class system, promises etc. really needed to be standardized because there were too many different solutions floating around and the fragmentation was hurting the ecosystem.&lt;p&gt;Personally, I think that ES6 is much more usable than any previous version of JavaScript.</text></comment>