Skip to content

Deploy on Deno ​

Choose Deno when creating a project. The initializer still runs through Node/npm, but the generated project develops and starts with Deno. Its main.ts uses limette/deno:

ts
// main.ts
import { serve } from "limette/deno";
// @ts-ignore Generated by the production Vite build.
import handler from "./dist/server/entry.js";

await serve(handler, {
  port: Number(Deno.env.get("PORT") ?? 8000),
  staticFiles: { root: "./dist/client" },
});
sh
deno task build
deno task start

The adapter calls Deno.serve, passing its request and Deno request information to the runtime-neutral handler. It accepts Deno serve options plus staticFiles. Without a specified port it tries ports 8000 through 8019. Static files are checked before the application handler when configured.

Deploy the generated dist/server/entry.js, dist/client, the launcher, and its dependencies to a Deno environment that supports this server setup.

Released under the MIT License.