Compare commits

1 Commits
v1.0.0 ... main

Author SHA1 Message Date
Robin Chappatte
7b8fc5d6c5 create script for builing npm package 2024-06-21 22:43:56 +02:00
2 changed files with 18 additions and 0 deletions

1
.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
npm/*

17
build-for-npm.ts Normal file
View File

@@ -0,0 +1,17 @@
import { build, emptyDir } from "https://deno.land/x/dnt@0.40.0/mod.ts";
await emptyDir("./npm");
await build({
entryPoints: ["./mod.ts"],
outDir: "./npm",
shims: {
// see JS docs for overview and more options
deno: true,
},
package: {
// package.json properties
name: "result",
version: Deno.args[0],
},
});