Compare commits

..

2 Commits

Author SHA1 Message Date
d39bdaa95f Merge pull request 'TSUP' (#3) from dev into main
Reviewed-on: #3
2024-09-15 12:33:23 +00:00
fca0f47fb0 TSUP 2024-09-15 14:32:53 +02:00
3 changed files with 2210 additions and 2 deletions

2192
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -1,10 +1,15 @@
{
"name": "app",
"version": "1.0.0",
"main": "index.ts",
"main": "./dist/index.ts",
"module": "./dist/index.mjs",
"types": "./dist/index.d.ts",
"files":[
"dist"
],
"scripts": {
"start": "ts-node src/index.ts",
"build": "tsc",
"build": "tsup",
"postinstall": "npm run build"
},
"keywords": [],
@ -13,6 +18,7 @@
"description": "",
"devDependencies": {
"ts-node": "^10.9.2",
"tsup": "^8.2.4",
"typescript": "^5.6.2"
}
}

10
tsup.config.ts Normal file
View File

@ -0,0 +1,10 @@
import { defineConfig } from "tsup";
export default defineConfig({
entry: ["src/index.ts"],
format: ["cjs", "esm"], // Build for commonJS and ESmodules
dts: true, // Generate declaration file (.d.ts)
splitting: false,
sourcemap: true,
clean: true,
});