MyGit

bun-v0.0.78

oven-sh/bun

版本发布时间: 2022-04-10 20:52:23

oven-sh/bun最新发布版本:bun-v1.1.20(2024-07-13 14:04:45)

To upgrade:

bun upgrade

What's new:

You can now import from "bun" in bun.js. You can still use the global Bun.

Before:

await Bun.write("output.txt", Bun.file("input.txt"))

After:

import {write, file} from 'bun';

await write("output.txt", file("input.txt"))

This isn't a breaking change – you can still use Bun as a global same as before.

How it works

Bun's JavaScript printer replaces the "bun" import specifier with globalThis.Bun.

var {write, file} = globalThis.Bun;

await write("output.txt", file("input.txt"))

You'll probably want to update types too:

bun add bun-types

Bug fixes

Bug fixes from v0.0.77

相关地址:原始地址 下载(tar) 下载(zip)

1、 bun-darwin-aarch64.dSYM.tar.gz 14.65MB

2、 bun-darwin-aarch64.zip 11.34MB

3、 bun-darwin-x64.dSYM.tar.gz 15.44MB

4、 bun-darwin-x64.zip 13.57MB

5、 bun-linux-x64.zip 26.65MB

查看:2022-04-10发行的版本