HN Reader

NewTopBestAskShowJob
Show HN: Almostnode – Run Node.js, Next.js, and Express in the Browser
score icon1
comment icon0
2 hours agoby PetrBrzyBrzek
Hey HN, I built almostnode. It's a library that gives you a Node.js-like environment inside the browser.

It includes: - A virtual filesystem with POSIX-compatible API - 40+ shimmed Node.js modules (fs, path, http, crypto, stream, etc.) - A package manager that installs real npm packages client-side - Built-in Next.js (App Router) and Vite dev servers with HMR - Service worker bridge that makes virtual servers accessible via real URLs

The main use cases are interactive code playgrounds, live documentation, and AI coding agents that need to execute code client-side without provisioning a sandbox server.

It's not a WebContainers replacement, no real TCP/IP or native modules. Think of it as the lightweight alternative when you just need a demo or playground running from a static HTML page.

It's experimental and definitely has bugs. Would love feedback, especially on the module shims and framework support.

GitHub: https://github.com/macaly/almostnode

No comments