Expressive ES6 features that shine in Node.js 4.0
The developers behind Node.js released version 4.0 last week. The new version is a major update that includes significant improvements and many new language features. It is the first release to incorporate improvements from io.js, a community-driven fork that recently reintegrated with upstream Node.js.
The io.js project emerged earlier this year when prominent Node.js contributors decided to go their own way, seeking more open governance and a more predictable release cycle. They recently resolved their differences with Joyent, the corporate steward of the Node.js project. Following the reconciliation, the upstream maintainers adopted the io.js code base.
Node.js 4.0 includes the latest and greatest version of the V8 JavaScript runtime, which opens the door for developers to use a number of new language features from the ECMAScript 6 (ES6) specification. In previous versions of Node, important ES6 features were only available while using experimental command line flags. Some of our favorite new features supported out of the box in Node.js 4.x include arrow functions, generators, for/of loops, and template strings.