Releases: oven-sh/bun
Bun v0.0.22
Features
- Support resolving
"exports"
field in package.json. Webpack's guide does a great job explaining the"exports"
field. - Add parsed lines of code counter to
bun bun
- Support importing files above the project root. HTTP Requests above the project root are allowlisted to specific file extensions to prevent common webserver security vulnerabilities like reading
/etc/passwd
. Absolute file path imports always start withabs:
. The security questions aren't as relevant for localhost development, but still worth thinking about. - Support bundling symlinked workspace packages via
bun bun
. To use this, set"bun": { "alwaysBundle": ["packageName"] }
in the project'spackage.json
. - When bundling JSON, print the output as
JSON.parse(jsonString)
when the JSON is ASCII.JSON.parse
is much faster for JavaScript engines to parse.
Bun.js
- Implement
console.time
,console.timeEnd
- Implement
Bun.readFileBytes()
to get a Uint8Array of the file's contents without copying.
Bug fixes
- Fix handling when file metadata store exceeds statically allocated count (at time of writing, 16k)
- Always log errors when generating
node_modules.server.bun
- Fix how error lines with strings are highlighted
- Fix parsing/printing JavaScript unicode identifiers
- Slightly improve .env loader string detection
- More correct
export default
transform for bundled code - Fix a JavaScript simplification bug involving ternaries
- Fix a JavaScript parsing bug with arrays in function arguments that have default values
- Fix edgecase with bare imports inside .bun
- Fix edgecase with whether to wrap arrow expressions in parentheses when printing
- Fix edgecase when a bundled module with multiple-levels of nested exports have a boolean value for the
default
export - Globally define
require()
so that UMD modules which check for the existence ofrequire()
to determine if it's CommonJS use the CommonJS code path instead of the globalThis code path. This is not great. - Embed regeneratorRuntime so that modules which expect it to be a global work
- Fix crash when loading JS fails really quickly
Misc
- Begin adding integration tests with snapshots that run with HMR disabled & HMR enabled
- Add comment explaining failed package.json parsing optimization
- Elaborate on
bun bun
in the readme - Switch to UTF-8 for prefilled strings, remove eagerly loading identifier_name
- Symlinks work but the readme wasn't updated
- Add skeleton code for macros but do not execute them yet
Bun v0.0.21
-
Package.json
-
Slightly improve JSX decoding perf
-
Fix whitespace & emoji bug when parsing JSX
Bun v0.0.19
Fix lexer bug with UTF-16 strings (escaped)
Bun v0.0.18
- global -> globalThis
- Fix symbol collision when using
require
unbundled to the same path multiple times
Bun v0.0.17
-
Colorize build/resolve errors and add a ^
-
Print absolute paths in log errors so that ctrl+click to open file in editor works (depending on terminal)
-
Delete some dead code
-
Always bold ^
-
When port is in use, auto-increment port number up to 10 times and then bail if all 10 are in use
-
Fix symbol name for cjs2esm
-
Help output should print command names
-
Add flag to dev server to disable HMR
-
Fix export * as from
-
Update options.zig
-
Do not attempt to HMR export {value} from, just assume it will be HMR'd (or not)
-
Fix bugs with ESM -> CJS when not bundled
-
Begin to add integration tests
-
Little more clarify readme
-
Add puppeteer to package.json
Bun v0.0.16
-
Switch to 0.0.x instead of 0.0.0-x to fix the npm install issue
-
write the version
-
Automatically rewrite TS import paths from .jsx? -> .tsx? when .jsx? is not found
This was already partially implemented but it was returning filenames instead of absolute paths. This matches the behavior from microsoft/TypeScript#4595.
Bun v0.0.15
Switch to 0.0.x versions to hopefully fix npm install bun-cli
Bun v0.0.0-14
-
Fix crash in
bun bun
-
Remove most usages of anytype in js_ast.zig
-
Fix CommonJS symbol names
-
Fix require bug in runtime.js
-
Bump
Bun v0.0.0-13
bun-v0.0.0-13 Bump
Bun v0.0.0-12
bun-v0.0.0-12 Add aarch64