Quick Summary
The Node.js core team is back with the latest version of the most renowned framework, Node.js 23. The 2024-released Node.js is power-packed with features and updates that will take the development experience and efficiency to the next level. In this blog post, we will take a brief look and dive deeper into exploring What’s New Node 23 and the new features and latest updates that the core team at Node.js has brought to us.
The Node.js team has officially announced the Node.js 23.0.0 version, marking a significant update with key advancements for developers. This time, the team has kept the official Node.js 23 release date of October 16, 2024. The latest version of Node.js 23 enlists many exciting new features, including enabling the use of require(esm) by default, improving testing tools, and removing support for 32-Windows systems. Here is a breakdown of the critical updates and their importance for the Node.js community.
With the release of Node.js 23.0.0, the previous version, NodeJS 22, is set to enter LTS or long-term support later this month, and the latest version is set to replace it as the ‘Current’ release line.
The most significant change introduced with the Node.js 23 version is enabling the require(esm) by default. Previously, developers had to use the –experimental-require-module flag to load native ES modules through require().
Now, this feature is enabled by default, making it more accessible for integrating modern ES modules into Node.js applications. Though, it is still in the experimental phase, it is indeed a step towards the full adoption to gather feedback before finalizing the feature.
If there are any regressions, the developers can easily disable the feature using the –no-experimental-require-module flag, allowing time for adjustments and improvement before its more comprehensive implementation.
Next in line is another exciting addition: stabilization of the node –run command. This feature simplifies the execution of Node.js scripts directly from the terminal without explicitly defining a file or script, making the development workflows more flexible and efficient.
The NodeJS 23 version improves the inbuilt test runner, supporting glob pattern matching the coverage files. This enhancement simplifies running the tests across multiple files, enabling developers to quickly achieve more precise coverage reports.
Node.js 23 introduces experimental TypeScript support, enabling developers to run TypeScript files with limited syntax transformation in Node.js directly. This removes the need for external transpilers, simplifying development workflows for TypeScript-based projects.
Another experimental addition is Web Storage API support. Developers can now use localStorage and sessionStorage in a Node.js environment, akin to how they are used in web browsers. This feature can be activated with the –experimental-webstorage flag.
OpenSSL 3 has deprecated support for custom engines, advising users to adopt its new provider model. As a result, the following Node.js options are impacted: clientCertEngine (used in https.request(), tls.createSecureContext(), and tls.createServer()), as well as privateKeyEngine and privateKeyIdentifier for tls.createSecureContext(), and crypto.setEngine().
The –experimental-policy option has been removed. Despite being tested for several years, fewer maintainers were available to support it, and recurring issues led to the decision to discontinue it, as further progress stalled.
In Node.js 23, the minimum required version for the GNU C/C++ compiler has been raised to gcc 12 to accommodate new C++20 features used in both Node.js and its dependencies, particularly V8. Additionally, support for 32-bit Windows has been dropped due to low usage, which no longer justified the resources needed to maintain it.
Node.js 23 continues to emphasize security with numerous patches for vulnerabilities, including fixes for CVEs in core and third-party dependencies. The project also focuses on automating its security release process, aiming to make releases faster and more reliable.
Hire NodeJS developers from us to upgrade your existing outdated NodeJS apps and ensure scalable and high-performance solutions!
Enabling the require(esm) allows your developers to load the native ES modules using the require() without facing the notorious ERR_REQUIRE_ESM error. However, the developers must consider that if an ES module or its dependencies use top-level await , Node.js will throw the ERR_REQUIRE_ASYNC_MODULE. To ensure a smooth integration, the developers can check if require(esm) is enabled using the process.features.require_module and detect compatibility via the “module-sync” export condition.
The said change is primarily important for modern JavaScript development, which allows the Node.js applications to integrate seamlessly with the broader JavaScript ecosystem that increasingly adopts the ES modules.
The Node.js 23.0.0 version brings aboard a number of new features with the other significant updates, it is recommended that developers thoroughly test their applications with Node.js 23 to ensure compatibility and use the new features and improvements.
For those maintaining legacy systems or requiring long-term stability, staying on Node.js 22 during the LTS may be a better choice. However, Node.js 23 offers many benefits for those looking to use modern features and performance enhancements.
The Node.js 23 release continues to push the tech stack forward, primarily with the streamlined handling of the ES modules and enhanced testing capabilities. While some developers need time to adjust to removing the 32-bit Windows support, the efficiency and ease of use make this Node 23 update an essential step for modern Node.js development and pave the path to the future of Node.js development. Make sure that you can explore the new features and consider how they can benefit from your workflows. If you are a business owner skeptical about making the call about whether you should upgrade your legacy applications to Node 23 or Node 22, leverage our Node.js Consulting Services. Our industry-vetted consultants will understand your requirements and guide you in making the right choice.
Your Success Is Guaranteed !
We accelerate the release of digital product and guaranteed their success
We Use Slack, Jira & GitHub for Accurate Deployment and Effective Communication.