Back
Deno Desktop turns Deno projects into self-contained desktop apps
SiTech AI Team3 წთ. საკითხავი

Deno Desktop turns Deno projects into self-contained desktop apps

Deno 2.9 introduces deno desktop, a command that compiles Deno projects into redistributable desktop binaries. The documentation positions it against Electron and Tauri, with small default binaries.

Deno has introduced deno desktop, a command that turns a Deno project — anything from a single TypeScript file to a Next.js application — into a self-contained desktop program. The output is a redistributable binary that bundles the project's code, the Deno runtime and a web rendering engine into one package per platform. The feature ships starting with Deno 2.9.0.

Positioned against Electron and Tauri

The documentation frames the tool as a response to the tradeoffs of existing web-based desktop stacks such as Electron, Tauri and Electrobun: large binaries, gaps in platform support, limited access to the JavaScript ecosystem, no built-in update story and no framework integration. Deno's answer is opinionated. The default WebView backend uses the operating system's own webview to keep binaries small, while the full npm ecosystem remains reachable through Deno's Node compatibility layer. Developers who need identical rendering on macOS, Windows and Linux can opt into a bundled Chromium backend based on CEF instead.

Framework detection and in-process bindings

Pointed at a Next.js, Astro, Fresh, Remix, React Router, Nuxt, SvelteKit, SolidStart, TanStack Start or Vite SSR project, the command runs the production server in release mode or the dev server with hot reload under --hmr; most frameworks need no special adapter. Communication between backend and interface goes through in-process channels rather than socket-based IPC, so values are still encoded as they cross the call boundary but there is no cross-process round-trip between Deno code and the webview. A single machine can build for macOS, Windows and Linux, with backends downloaded as needed rather than compiled locally.

Updates, and a worked example

Auto-update is built in: developers publish one latest.json manifest and bsdiff patches, and the runtime polls, applies and rolls back automatically if a launch fails. A minimal app is a single file that calls Deno.serve(); the compiled binary opens a window pointed at that local HTTP server, and Deno binds to the address the webview navigates to, so no port or hostname has to be configured. The documentation points to denidian, an Obsidian-style note-taking app with Markdown notes, wikilink crosslinking and a graph view, as a complete example covering window management through Deno.BrowserWindow, application menus, development with --hmr and packaging for distribution.

Documentation also covers configuration through the desktop block in deno.json, the CEF, webview and raw backends, HTTP serving, framework requirements, window lifecycle and events, WebGPU rendering, bindings, menus, tray and dock integration, native dialogs and notifications, DevTools, error reporting, cross-compilation and installers.

SSiTech

SiTech — AI-powered web development

We build fast, modern websites and bring AI into real business workflows. Have a project or a question? We'd love to help.