Show HN: Belgie – Run TypeScript from Python in an Embedded Deno Sandbox (github.com)

5 points by mplemay97 ↗ HN
Hi HN! I built Belgie, a Python library that embeds Deno, allowing Python applications to run JavaScript and TypeScript without requiring Node.js or Deno to be installed on the host system. It supports the features you’d expect from Deno (npm, JSR, and URL imports, isolated package environments, etc.), plus:

- Pass JSON-safe values seamlessly between Python and JavaScript.

- Agentic code generation with typed interfaces, similar to Pydantic’s Monty.

- Manage dependencies programmatically or from the CLI.

1 comment

[ 3.4 ms ] story [ 17.2 ms ] thread
Neat. Deno is packaged on PyPI now, so installation isn't a real issue; but it's nice to be able to invoke the runtime directly rather than by shelling out. Maybe yt-dlp could make use of it?