Perhaps a bit awkwardly named but nice:<p>> bun --smol is a new CLI flag which configures the JavaScriptCore heap size to be smaller and grow slower, at a cost to runtime performance. This is useful for running Bun in memory-constrained environments.<p>From the example they gave (<a href="https://i.imgur.com/IDHTaAh.png" rel="nofollow noreferrer">https://i.imgur.com/IDHTaAh.png</a>):<p><pre><code> Bun 343 MB
Bun with --smol 54 MB
Node.js 138 MB</code></pre>
Honestly, I havent been a nodejs dev for a long time.<p>However from the outside in, if an alternative runtime was to steal the show so to speak, then Bun looks like it might be able to do it.<p>- Full interoperability with the existing ecosystem<p>- Typescript and JSX as first class<p>- Blazing fast compile times<p>- Can serve a very large number of concurrent requests<p>- And a standard library that does as much as the go stdlib<p>Someone please tell me why this is a bad project, because so far I want to jump in.
Doesn't work on my system unfortunately (WSL 2)<p><pre><code> LAPTOP-162NUQO7:~$ curl -fsSL https://bun.sh/install | bash
######################################################################## 100.0%
bun was installed successfully to ~/.bun/bin/bun
Manually add the directory to ~/.bashrc (or similar):
export BUN_INSTALL="$HOME/.bun"
export PATH="$BUN_INSTALL/bin:$PATH"
To get started, run:
bun --help
LAPTOP-162NUQO7:~$ ~/.bun/bin/bun
Error relocating /home/lewis/.bun/bin/bun: unsupported relocation type 37
Error relocating /home/lewis/.bun/bin/bun: unsupported relocation type 37
Error relocating /home/lewis/.bun/bin/bun: unsupported relocation type 37</code></pre>
Does anyone know why Bun (without --smol) sometimes uses much more memory than Node? Is this due to not being v1 yet?<p>I'm also wondering if some old benchmarks could now be irrelevant.
Not having much luck running non-strict Node.JS classic scripts in Bun using CommonJS/require. Errors about strict mode despite not using "use strict";. Is there a flag to allow such scripts to run?
Has anyone managed to get bun running with ChatGPT Code Interpreter?<p>I can get all the help text displaying but there's no output or error when running a JS file with the latest release (or even one from last year).<p>The latest Deno release works out the box with Code Interpreter. There might not be much benefit to running Bun over Deno but if like to try.
Going to <a href="https://github.com/oven-sh/bun">https://github.com/oven-sh/bun</a><p>It seems bun is:<p>Zig
52.0%<p>C++
19.2%<p>JavaScript
14.6%<p>TypeScript
12.1%<p>...<p>which is an interesting mix. I assume the JS is intended to be TS eventually or actually is right now. But why all the C++?
Is it only me that finds it strange that engineers working in a particular language will get another language to solve issues with said language? e.g. Javascript using C, C++, Zig, Rust, etc. Ruby and Python is also similar situation there are tools, libraries and such built in other languages