Hacker News new | ask | show | jobs
by lucasyvas 1681 days ago
I'd be curious to know how language decisions are made for this tool. I notice Wrangler v1 is Rust, and now this has flipped back to JS/TS. Was the motivation largely driven by Miniflare, which is based on Node?

Nice feature set though!

1 comments

Hello! I'm on the team that implemented this. I'll be writing a longer post on the design considerations and implementation details, but roughly - rust wasn't a good case for something that was mostly held back by i/o to the edge; further, the actual cpu/mem intensive part was handed off to webpack which was written in javascript. So wrangler v2 flips that design around, using typescript for the outer shell, which makes it easier for our users and community to contribute to the tool, and esbuild for the core part of parsing/bundling code (we may switch esbuild to a rust based bundler like swc in the future).
Thanks for the background!