Skip to main content
Deno 2 is finally here 🎉️
Learn more

esbuild_deno_loader

Deno module resolution for esbuild.

Example

This example bundles an entrypoint into a single ESM output.

import * as esbuild from "https://deno.land/x/esbuild@v0.12.9/mod.js";
import { denoPlugin } from "https://deno.land/x/esbuild_plugin_deno@0.1.0/mod.ts";

await esbuild.build({
  plugins: [denoPlugin()],
  entryPoints: ["https://deno.land/std@0.95.0/hash/sha1.ts"],
  outfile: "./dist/sha1.esm.js",
  bundle: true,
  format: "esm",
});
esbuild.stop();