-
-
Notifications
You must be signed in to change notification settings - Fork 102
Expand file tree
/
Copy pathtsdown.config.ts
More file actions
24 lines (23 loc) · 726 Bytes
/
tsdown.config.ts
File metadata and controls
24 lines (23 loc) · 726 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import { glob } from "node:fs/promises";
import { sep } from "node:path";
import { defineConfig } from "tsdown";
export default [
defineConfig({
entry: ["src/mod.ts", "src/jsonld.ts", "src/temporal.ts"],
dts: { compilerOptions: { isolatedDeclarations: true, declaration: true } },
format: ["esm", "cjs"],
platform: "neutral",
deps: { neverBundle: [/^node:/] },
banner: {
dts: `/// <reference lib="esnext.temporal" />`,
},
}),
defineConfig({
outDir: "dist/tests",
entry: (await Array.fromAsync(glob(`src/**/*.test.ts`)))
.map((f) => f.replace(sep, "/")),
format: ["esm", "cjs"],
platform: "node",
deps: { neverBundle: [/^node:/, "@fedify/fixture"] },
}),
];