"scripts": {
"clean": "rm -rf dist",
"dev:watch": "npm run clean && tsup --watch src/index.ts --onSuccess 'node dist/index.js'",
"build": "npm run clean && tsup"
}
{
"compilerOptions": {
"target": "ES2020",
"module": "CommonJS",
"lib": ["ES2020"],
"outDir": "dist",
"rootDir": "src",
"strict": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"skipLibCheck": true,
"moduleResolution": "node",
"resolveJsonModule": true,
"noImplicitAny": true
},
"include": ["src"],
"exclude": ["node_modules", "dist"]
}
import { defineConfig } from 'tsup'
export default defineConfig({
entry: ['src/index.ts'],
splitting: false,
sourcemap: true,
clean: true,
})