Skip to content

Commit abbc7ba

Browse files
committed
chore: migrate bundler from unbuild to tsdown
1 parent 41ac23a commit abbc7ba

File tree

3 files changed

+402
-976
lines changed

3 files changed

+402
-976
lines changed

lib/package.json

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,17 @@
88
"sideEffects": false,
99
"type": "module",
1010
"exports": {
11-
".": {
12-
"types": "./dist/index.d.ts",
13-
"import": "./dist/index.mjs"
14-
}
11+
".": "./dist/index.js",
12+
"./package.json": "./package.json"
1513
},
16-
"main": "./dist/index.mjs",
17-
"module": "./dist/index.mjs",
14+
"main": "./dist/index.js",
15+
"module": "./dist/index.js",
1816
"types": "./dist/index.d.ts",
1917
"files": [
2018
"dist"
2119
],
2220
"scripts": {
23-
"build": "unbuild",
21+
"build": "tsdown",
2422
"dev": "astro dev --port 3000",
2523
"format": "prettier src --check",
2624
"format:fix": "prettier src --write",
@@ -42,13 +40,13 @@
4240
"eslint": "9.32.0",
4341
"eslint-config-unjs": "0.5.0",
4442
"prettier": "3.6.2",
45-
"typescript": "5.8.3",
46-
"unbuild": "3.6.0"
43+
"tsdown": "0.14.1",
44+
"typescript": "5.8.3"
4745
},
4846
"changelog": {
4947
"excludeAuthors": [
5048
""
5149
]
5250
},
53-
"packageManager": "pnpm@10.13.1"
51+
"packageManager": "pnpm@10.14.0"
5452
}

lib/tsdown.config.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
import { defineConfig } from "tsdown";
2+
3+
export default defineConfig({
4+
entry: ["./src/index.ts"],
5+
platform: "browser",
6+
exports: true,
7+
});

0 commit comments

Comments
 (0)