Read Bun v0.3.0's release notes on Bun's blog
To install:
curl -fsSL https://bun.sh/install | bash
To upgrade:
bun upgrade
There were a lot of changes! Here's the complete list:
- Fixed various memory leaks -
a9aa3e7
,1cce9da
,9090f06
- Implemented
process.release
-901c4f5
- Fixed various bugs with
RegExp
-5398ed5
,#1537
,#1528
,74e87b5
- Fixed an issue with
fs.stat()
-f9f169b
- Prevented
process.stdout
andprocess.stderr
from being closed -8519ff0
- Changed behaviour of
Blob.size
to reportInfinity
for non-files -d5c81b7
- Fixed incorrect
exitCode
fromspawn()
-30e1fe1
- Fixed incorrect transpilation of
export = value
in TypeScript -1cb5a73
- Fixed
spawn()
not being killed when parent process is killed -1f174b9
- Fixed silent error when
port
was not a number -e5b2e3c
- Added a
done
callback to support async functions inbun:test
-c00359a
- Fixed various issues with
process.nextTick()
-fd26d2e
,2eb19a9
- Fixed
console.log(Request)
showing an emptyurl
-cb41d77
- Implemented
AbortSignal.timeout()
-fe4f39f
- Supported wildcard
imports
in package.json -a3dc33c
- Fixed timers keeping the process alive unnecessarily -
f408749
- Fixed an issue when object spreading
process.env
-a6cadce
- Fixed a bug where
Response.arrayBuffer()
would return aUint8Array
-de9a2b9
- Implemented
signalCode
forBun.spawn()
-0617896
- Supported the
Content-Range
header when serving a file -0617896d
- Supported
bin
when usingbun link
-0642cf3
- Improved the output of
console.log()
-c65c320
- Fixed an issue with streams prematurely closing -
d68f44d
- Fixed an issue when using
console.log()
with an emoji -3cb462a
- Fixed an issue when connecting to
localhost
-d90a638
- Fixed
Request.url
not showing the value from theHost
header -da25733
- Fixed memory issues in
HTMLRewriter
wheretext
was not properly cloned -a85826
,904716f
- Fixed an issue when an exception is throw within a
WebSocket
open event -c52ebd9
- Added support for npm packages that do not have a
-
before a pre-release identifier (e.g.1.0.0beta
) -5f5ef81
- Improved performance of IO polling for
Bun.spawn()
andnode:child_process
-#1496
- Fixed infinite IO
write()
on Linux -a78b6f9
- Added support for
fs.rmdir()
-92b7660
- Fixed an issue with gzip decompression when the body was not gzipped -
#1510
- Fixed an issue with
@
in the URL offetch()
-6c01a11
- Fixed an issue with a trailing
/
in the URL offetch()
-4f22c39
- Fixed rare crash during
console.log()
-b0c89ba
- Improved support for
node:http.createServer()
-bf6b174
- Implemented
FileSink.ref()
andFileSink.unref()
-d1a4f4f
- Implemented
console.timeLog()
-f677919
- Fixed
fs.createWriteStream()
-#1433
- Supported TypeScript decorators -
#1445
- Supported JavaScript callbacks using
bun:ffi
-81033c5
- Added a property for JavaScript callbacks to be marked as
threadsafe
usingbun:ffi
-006a2f3
- Fixed various
WebCrypto
issues and crashes -#1448
,#1450
- Fixed
Bun.which()
not handling absolute paths -d6520cd
- Allowed URLs to be used as an argument to
fetch()
-#1460
- Fixed rejected promises not triggering a test failure in
bun:test
-370d9c
- Fixed environment variables being coerced to non-strings -
#1256
- Made
TextDecoder
20% faster for small inputs -160466
- Fixed incorrect value for
os.EOL
-8b0a3c7
- Fixed
Buffer.toString("base64")
sometimes being incorrect -af39313
- Fixed incorrect file permissions when using
bun install
-2c4777
- Supported TypeScript
satisfies
-565996
- Implemented
WebSocketServer.publish()
when invoked outside an event handler -8753c48
- Improved performance of Node.js streams -
#1502
- Fixed
bun:sqlite
truncating numbers to int32 instead of int52 -ce6fc86
- Fixed HTTP status text not matching standards -
949d715
- Fixed
bun:sqlite
not properly handing latin1 characters -c65c320
- Supported manual redirects in
fetch()
-5854d39
- Fixed
fetch()
redirects loosing theport
-f8d9a8b
- Fixed an issue with a malformed
fetch()
response body -b230e7a