feat: add tsdown.config.ts (#379)

This commit is contained in:
CodeWithShreyans 2025-08-23 17:40:04 +00:00
parent 9d603015ab
commit da033f19ec
No known key found for this signature in database
GPG key ID: A1B43A0A7B74CD2C
4 changed files with 53 additions and 26 deletions

View file

@ -0,0 +1,5 @@
src/
.turbo/
.env
tsdown.config.ts
tsconfig.json

View file

@ -1,27 +1,32 @@
{
"name": "@supermemory/ai-sdk",
"version": "1.0.0",
"main": "dist/index.mjs",
"types": "dist/index.d.mts",
"scripts": {
"build": "tsdown",
"dev": "tsdown --watch",
"check-types": "tsc --noEmit",
"test": "vitest",
"test:watch": "vitest --watch"
},
"dependencies": {
"@ai-sdk/openai": "^2.0.15",
"@ai-sdk/provider": "^2.0.0",
"ai": "^5.0.17",
"supermemory": "^3.0.0-alpha.22",
"zod": "^4.0.17"
},
"devDependencies": {
"@total-typescript/tsconfig": "^1.0.4",
"@types/bun": "^1.2.20",
"tsdown": "^0.14.1",
"typescript": "^5.9.2",
"vitest": "^3.2.4"
}
"name": "@supermemory/ai-sdk",
"version": "1.0.1",
"scripts": {
"build": "tsdown",
"dev": "tsdown --watch",
"check-types": "tsc --noEmit",
"test": "vitest",
"test:watch": "vitest --watch"
},
"dependencies": {
"@ai-sdk/openai": "^2.0.15",
"@ai-sdk/provider": "^2.0.0",
"ai": "^5.0.17",
"supermemory": "^3.0.0-alpha.22",
"zod": "^4.0.17"
},
"devDependencies": {
"@total-typescript/tsconfig": "^1.0.4",
"@types/bun": "^1.2.20",
"tsdown": "^0.14.1",
"typescript": "^5.9.2",
"vitest": "^3.2.4"
},
"main": "./dist/index.mjs",
"module": "./dist/index.mjs",
"types": "./dist/index.d.mts",
"exports": {
".": "./dist/index.mjs",
"./package.json": "./package.json"
}
}

View file

@ -5,6 +5,8 @@
"paths": {
"@/*": ["./*"],
"@lib/*": ["../lib/*"]
}
},
"declaration": true,
"declarationMap": true
}
}

View file

@ -0,0 +1,15 @@
import { defineConfig } from "tsdown"
export default defineConfig({
entry: ["src/index.ts"],
format: "esm",
sourcemap: true,
target: "es2020",
tsconfig: "./tsconfig.json",
clean: true,
minify: true,
dts: {
sourcemap: true,
},
exports: true,
})