This is mostly a port of the amazing Deno esbuild Plugin. Rolldown is currently pre-1.0 and this plugin has no production-ready guarantees.
Plugin to enable Deno resolution inside rolldown. It supports:
- Alias mappings in
deno.json npm:specifierjsr:specifierhttp:andhttps:specifiers
- Install this package
- Import it and add to the
rolldownconfig
import * as rolldown from "rolldown";
import { denoPlugin } from "@lulu/deno-rolldown-plugin";
await rolldown.build({
input: ["./main.ts"],
output: { file: "./main.bundle.js" },
plugins: [denoPlugin()],
});