18 lines
400 B
TypeScript
18 lines
400 B
TypeScript
|
import { defineConfig } from "tsup";
|
||
|
|
||
|
export default defineConfig((options) => ({
|
||
|
entry: ["src/index.ts", "src/preview.ts", "src/manager.ts"],
|
||
|
splitting: false,
|
||
|
minify: !options.watch,
|
||
|
format: ["cjs", "esm"],
|
||
|
dts: {
|
||
|
resolve: true,
|
||
|
},
|
||
|
treeshake: true,
|
||
|
sourcemap: true,
|
||
|
clean: true,
|
||
|
platform: "browser",
|
||
|
esbuildOptions(options) {
|
||
|
options.conditions = ["module"];
|
||
|
},
|
||
|
}));
|