Bun 1.1 comes with Windows support, better Node.js compatibility & stable WebSocket client
Bun, the JavaScript and TypeScript development tool, has launched version 1.1, following over 1,700 commits since the release of Bun 1.0. The team has focused on Windows support, enhancing stability, and Node.js compatibility.
In a significant development, Bun has extended support to Windows, enabling users to run the tool on Windows 10 and later versions. According to the Bun team, the tool's performance on Windows matches 98% of their test suite for Bun on macOS and Linux. Users can execute commands such as bun install, bun run, and bun --watch on Windows.
Performance-wise, Bun 1.1 demonstrates up to 2x speed compared to Bun 1.0 when launching and operating large projects. This is due to the introduction of a content-addressable cache for files exceeding 50 KB, which mitigates the performance lag of transpiling identical files repeatedly.
The updated version also supports node:http2 client APIs, facilitating outgoing HTTP/2 requests. Consequently, packages like @grpc/grpc-js can be deployed to dispatch gRPC requests over HTTP/2. However, the team is yet to introduce support for the HTTP/2 server.
Bun 1.1 complies with Web standard APIs, including fetch() and Response, simplifying the process of writing code compatible with both the browser and Bun. WebSocket, now stable in Bun 1.1, successfully passes the Autobahn conformance test suite, rectifying numerous bugs in the WebSocket client and enhancing its reliability for production use.
The latest version also incorporates numerous added or improved Node.js APIs, a cross-platform Bun Shell, and other minor modifications and bug resolutions.
