4 ms·
I just tried Bun to make a script to copy files from a service we were moving off of to S3 and it's pretty great. Instead of having to tinker with my package.j
by cdmckay 2y ago
I just tried Bun to make a script to copy files from a service we were moving off of to S3 and it's pretty great.
Instead of having to tinker with my package.json, tsconfig.json, etc. to get everything just right, it works right of the box the way you expected with `bun init`.
Then it's just `bun run index.ts`.
And it's fast!
Node is great but there's just too many options to configure. I appreciate that Bun went ahead and made a bunch of assumptions and pulled commonly used stuff directly into it.
- XCSme 2y ago> Node is great but there's just too many options to configure What exactly do you have to configure in Node?
- wiseowise 2y agoTypescript, to start with.
- XCSme 2y agoLatest Node can run TypeScript: https://2ality.com/2025/01/nodejs-strip-type.html https://2ality.com/2025/01/nodejs-strip-type.html
- gr4vityWall 2y agoTypeScript, maybe handle some CJS vs ESM incompatibility while at it, and a hot reload solution are what come to mind initially.
- XCSme 2y agoLatest Node can run TypeScript: https://2ality.com/2025/01/nodejs-strip-type.html https://2ality.com/2025/01/nodejs-strip-type.html
- gr4vityWall 2y agoI'm aware of that initial support, I've been followed that since they added the experemental flag. As far as I know, it requires some non-standard usages in TS code, like adding the .ts extension to your imports at the top of your TypeScript files. It doesn't support .tsx files or any TypeScript feature that requires more than type striping. The initial support is appreciated, but it's not on part with Deno or Bun yet. TL;DR you will still need to work on adding proper TypeScript support anyway, compared to Bun.