Blog Editor with a profound interest in software development and advancements of technology.
October is an exciting month for Node.js enthusiasts as it brings the anticipation of both a fresh Node.js major release, Node.js 21, and the imminent transition of Node.js 20 to Long Term Support (LTS) status in the following week. This sense of predictability and orderliness in the Node.js community's well-established release procedure is truly noteworthy.
In this new article, we will go over the significant enhancements in Node.js, with a special focus on the introduction of a built-in WebSocket client and support for globs in the platform’s test runner.
Node.js 21 has seen significant development with over 1153 commits since the release of 20.0.0. However, it's important to note that a substantial portion of this work involved improvements and restructuring of existing features, resulting in a limited number of prominent new features. Some notable changes worth highlighting encompass:
You can enable support for a browser-compatible implementation of WebSocket using the
--experimental-websocket flag. This is another step towards enabling Web APIs in Node.js and enhancing cross-platform development capabilities.
--experimental-default-type flag allows you to set defaults that are better suited for fully ESM (ECMAScript Modules) implementations. This focuses on improving the developer experience for those using ESM while maintaining compatibility with CommonJS.
Node.js 21 updates the minimum supported levels for platforms and tooling. Notably, the minimum supported macOS version has been increased to 11.0, and support for Visual Studio 2019 has been dropped.
Node.js 21 brings npm up to version 10.2, which includes various enhancements and new features. You can explore the specifics of this npm release in the official npm release notes.
The Node.js security team has automated the process of updating dependencies, ensuring that Node.js stays up to date with the latest versions of its dependencies. This release incorporates updates to various dependencies, such as uvwasi, simduft, zilb, googletest, undici, and ada.
In addition to the Node.js 21 release, Node.js 20 has been promoted to LTS (Long-Term Support), making it a stable choice for production use. Some notable features and initiatives from Node.js 20 include:
Stable Test Runner: Node.js 20 introduced a stable test runner to facilitate testing of Node.js applications.
WASI (WebAssembly System Interface): WASI, which was previously experimental and required a command line flag, is now a more integral part of the Node.js ecosystem.
Permission Model (Experimental): Node.js 20 introduced an experimental permission model to manage access to resources and system-level capabilities.
Single Executable Applications (Experimental): This feature allows the creation of single executable applications, simplifying deployment and distribution.
Tracing Channel (Experimental): Node.js 20 introduced a tracing channel for monitoring and diagnostics.
The Node.js project remains highly active and is making significant strides in addressing its technical priorities, as evident in the Node.js 20 and 21 releases. The Next-10 team has transitioned from merely identifying important project tasks to actively monitoring the progress and evolution of these critical initiatives. The substantial participation in the recent survey underscores the alignment between the project's documented technical priorities and the ecosystem's actual needs, emphasizing the project's responsiveness and relevance to its community.
You can read about all the new features and changes in the community post>>.
LEARN HOW WE CAN
ACCELERATE YOUR BUSINESS
Jounieh, Haret Sakher Highway,
+961 9 918 718/9
+961 71 918718
Copyrights © 2023 All Rights Reserved