Have no fear... Node.js 10 is here (since April 24, actually)! And, as expected, this version is planned to grow into the platform's official Long Term Support version (in October 2018); to be supported for 3 years after that date.

So? What's in it for you, the back-end web developer?

Are there any new features and improvements worth getting really excited about? Which are they and how precisely will they improve the overall developer experience. 

Now before we take a deep dive into the “steamy fresh load” of new features, I feel like pointing out that:

  1. it's mostly incremental improvements, applied throughout the entire codebase of the platform, that Node.js 10 ships with
  2. … performance, reliability and stability-centered improvements, bubbling up to the back-end developer's experience

But let's name these improvements that ship with the new version of Node.js. Let's talk specific incremental changes, shall we?

10 of the “really worth getting excited about” ones:

1. Error-Handling Improvements

And error messages/error-handling improvements do make the majority of semver-major commits (approx. 300) that Node.js ships with.

It's a “pledge” made since Node.js 8.0.0 to assign static error codes to all Error objects:

“Error messages should be useful, more consistent and predictable”, this has been the “pledge” driving all the sustained efforts geared at improving error-handling.

Note: error codes have been included in Node.js 10, making constant error-checking conveniently easier!

2. Enhanced JavaScript Language Capabilities

There's an entire list of Node.js 10 language improvements (you can find them all here) worth exploring and... exploiting, I'll outline the highlights only:

  • you now get to use line and paragraph separator symbols (U+2028 and U+2029) in string literals, that match JSON
  • V8 “introduces”: String.prototype.trimEnd(), String.prototype.trim(), String.prototype.trimStart()
  • prototype.toString() returns the exact “pieces” of the source code text (comments and whitespace here included!)
  • the catch clause of the try statements no longer calls for a parameter

3. The Node.js fs (file system) Has Been Significantly Overhauled

And here are the most “dramatic” improvements made during this overhaul:

  • the type checking and error handling have been improved
  • the code got restructured, for easier maintainability
  • a new experimental fs/promises API got implemented, featuring first-class Promise-based API 

Speaking of this new API, its “role” is that of generating a warning at runtime, the very first time that it gets used. Hopefully, things will turn out “bugs-free” so that it can grow from experimental to stable.

4. Node.js 10 Ships with Full Support for N-API 

N-API — the ABI stable (Node.js) API for native modules — has leveled up to a stable version in Node.js 10.

What does this mean?

  1. it provides a stable module API, one that is not influenced by the changes in Node.js's V8 JavaScript engine
  2. the API layer makes upgrading a whole lot easier, streamlining production deployments and... easing module maintainers' lives
  3. … and it goes without saying that this bubbles up to native modules' maintenance costs, as well

In short: say goodbye to module breakage!

5. The Assert Module: Explore Some Crucial Improvements 

All efforts targetting the assert module have been aimed at easing the internal implementation and improving the developer experience.

But let me point out some of these improvements that eventually fleshed out and landed in Node.js 10:

  • a new “diff” view got implemented, for whenever assertion errors get generated
  • overall the output becomes more descriptive, more... “verbose” (and implicitly more useful)
  • better object comparisons
  • promises support 
  • detailed error messages

6.  Node.js 10 Ships With V8 6.6: Expect a Major Performance Boost

Get ready to “exploit” V8 6.6's range of performance improvements to their full potential! Along with its new set of JavaScript language features!

From them all, I can't but mention:

  • the async functions
  • the async generators
  • the promise execution

7. Cryptographic Support 

Node.js 10 is the first version of the platform to include OpenSSL 1.x! And this can only translate into:

Enhanced protection for your priceless data!

Now, if I am to outline just 2 of the OpenSSL features to look forward tapping into, I should definitely mention:

  1. the Polu1305 authenticator
  2. the ChaCha 20 cipher

8. The Trace Events Mechanism: Monitoring Your Code's Performance Just Got Easier

That's right! Keeping a close eye on how your code's performing and being able to quickly diagnose any emerging issues is easier than ever with Node.js 10!

Basically, what these trace events do is enabling that all the diagnostic information output gets collected to a file accessible to the Chrome browsers DevTools utility.

No need to use a command-line flag anymore to trigger this whole trace events mechanism underlying Node.js.

And since we're here, let me point out to you 2 trace events-related improvements worth getting (really) excited about:

  1. the node.perf.usertiming category got added — its role is that of capturing, in the trace events timelines, all the Performance API user timer marks and measures. 
  2. the JavaScript API got implemented, as well; enabling/disabling trace events dynamically is now possible in Node.js:
const trace_events = require('trace_events')
const tracing = trace_events.createTracing({
  categories: ['node.async_hooks', 'v8']
// do stuff

9. HTTP and HTTP/2 Improvements 

Another thing to get excited about, when it comes to Node.js 10's release, is given by all the incremental improvements made to HTTP and HTTP/2.

Let me detail a bit:

  1. when it comes to HTTP, the changes applied range from improved Streams API compatibility to stricter standards support, to improve header and error handling
  2. now when it comes to HTTP/2, significant progress has been made for getting it the closest to “stable mode” as possible before Node.js 10 reaches its Long Terms Support cycle. And I'm talking here about improvements made to the way trailing headers requests and responses get implemented and about overall improvements of the internal implementation and the public API

10. Node.js Ships With The Experimental Node-ChakraCore

And how does this impact the developer experience? Your experience?

  • using the JavaScript engine to its full potential
  • tapping into the Time Travel debugging

… gets a whole lot easier for you. You're practically enabled to detect errors way before they even get to “infest” your code.

The END! This is how our list of 10 Node.js 10 features worth getting (really) excited about looks like! Do explore them and start your preparations for moving over to this new version of Node.js before October!


We do Web development

Go to our Web development page!

Visit page!

Browse cities

Recommended Stories

Migrating from other CMS to Drupal: A Step-by-Step Guide for 2024
IntroductionIf you are planning to move your site or project to Drupal 10, it means that you already know about… (Read more)
20 minutes /
Building Secure and Compliant Drupal Websites for Government Agencies
Building Secure and Compliant Drupal Websites for Government AgenciesGone are the days when government websites… (Read more)
10 minutes /
Best Drupal Modules for Higher Education Websites
IntroductionYou probably have seen Drupal empowering many companies and organizations in diverse industries:… (Read more)
15 minutes /