Bun 1.1 JavaScript toolkit backs Windows 10

Bun 1.1 also features speed and reliability updates and improvements for Node.js compatibility.

 Bun 1.1 JavaScript toolkit backs Windows 10
frank mckenna (CC0)

Bun 1.1, the latest version of the Bun toolkit and drop-in Node.js replacement for building, testing, and running JavaScript and TypeScript, now supports Windows 10. The latest version is also more compatible with Node.js.

Announced April 1 and described as a “huge update,” Bun 1.1 is said to be faster and more reliable than earlier releases, with many bug fixes. Bun now supports Windows 10 and higher, making the runtime accessible to Windows developers. Everything from the Bun runtime to the test runner, package handler, and bundler will work on Windows.

Intended as a drop-in replacement for Node.js, Bun now supports node:http2 client APIs for making outgoing HTTP2 requests. However, work is ongoing for the HTTP2 server. Developers now can send IPC messages between Bun and Node using the ipc option.

Bun's developers have also implemented a content-addressable cache for files larger than 50KB, which avoids the performance overhead of transpiling the same files repeatedly. Command-line tools such as tsc run as much as twice as fast in Bun 1.1. Bun also now works as a cross-platform shell akin to Bash, but also on Windows. A new Semver API, meanwhile, is featured for parsing and sorting semver strings.

Additionally, WebSocket is stable in Bun 1.1, and passes the Autobahn conformance test suite. The Websocket client is more reliable for production use. Bun now also supports the user-timings APIs, including APIs such performance.mark() and performance.measure(). This is useful for measuring application performance.

Bun also now supports module mocking, with the ability to mock ESM and CommonJS modules. The l.1 version adds built-in support for the SQLite C-language engine that implements a SQL database engine. A SQLite database can be imported using the import syntax.

Installation instructions for Bun can be found on the project website.

Copyright © 2024 IDG Communications, Inc.