Bun 1.1, the newest model of the Bun toolkit and drop-in Node.js substitute for constructing, testing, and operating JavaScript and TypeScript, now helps Home windows 10. The most recent model can also be extra appropriate with Node.js.
Introduced April 1 and described as a “big replace,” Bun 1.1 is alleged to be quicker and extra dependable than earlier releases, with many bug fixes. Bun now helps Home windows 10 and better, making the runtime accessible to Home windows builders. All the pieces from the Bun runtime to the take a look at runner, package deal handler, and bundler will work on Home windows.
Meant as a drop-in substitute for Node.js, Bun now helps node:http2
shopper APIs for making outgoing HTTP2 requests. Nonetheless, work is ongoing for the HTTP2 server. Builders now can ship IPC messages between Bun and Node utilizing the ipc
choice.
Bun’s builders have additionally carried out a content-addressable cache for recordsdata bigger than 50KB, which avoids the efficiency overhead of transpiling the identical recordsdata repeatedly. Command-line instruments corresponding to tsc
run as a lot as twice as quick in Bun 1.1. Bun additionally now works as a cross-platform shell akin to Bash, but additionally on Home windows. A brand new Semver API, in the meantime, is featured for parsing and sorting semver
strings.
Moreover, WebSocket
is secure in Bun 1.1, and passes the Autobahn conformance take a look at suite. The Websocket
shopper is extra dependable for manufacturing use. Bun now additionally helps the user-timings APIs, together with APIs such efficiency.mark()
and efficiency.measure()
. That is helpful for measuring software efficiency.
Bun additionally now helps module mocking, with the flexibility to mock ESM and CommonJS modules. The l.1 model provides built-in assist for the SQLite C-language engine that implements a SQL database engine. A SQLite database could be imported utilizing the import
syntax.
Set up directions for Bun could be discovered on the venture web site.
Copyright © 2024 IDG Communications, Inc.