Skip to content

Commit 116ba72

Browse files
committed
add dist typecheck and export routes
1 parent e46175b commit 116ba72

File tree

5 files changed

+581
-197
lines changed

5 files changed

+581
-197
lines changed

.github/workflows/dist-typecheck.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,8 @@ jobs:
3030
registry-url: "https://registry.npmjs.org"
3131
cache: "pnpm"
3232

33-
- name: Build ${{ matrix.package }} package and dependencies
34-
# build the package and all its dependencies
35-
run: pnpm --filter ${{ matrix.package }}... build
33+
- name: Install dependencies
34+
run: pnpm install --frozen-lockfile
3635

3736
- name: Check types with @arethetypeswrong/cli
38-
run: pnpx @arethetypeswrong/cli --pack packages/${{ matrix.package }} --profile esm-only
37+
run: pnpm --filter ${{ matrix.package }} typecheck:dist

packages/start-nitro-v2-vite-plugin/package.json

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,23 +5,30 @@
55
"type": "module",
66
"scripts": {
77
"build": "tsc",
8-
"typecheck": "tsc --noEmit"
8+
"typecheck": "tsc --noEmit",
9+
"typecheck:dist": "pnpm build && pnpx @arethetypeswrong/cli --pack . --profile esm-only"
910
},
11+
"files": [
12+
"dist",
13+
"package.json",
14+
"README.md"
15+
],
16+
"main": "./dist/index.js",
17+
"types": "./dist/index.d.ts",
1018
"exports": {
11-
".": "./src/index.ts",
12-
"types": "./dist/index.d.ts"
19+
".": {
20+
"types": "./dist/index.d.ts",
21+
"default": "./dist/index.js"
22+
}
1323
},
1424
"publishConfig": {
15-
"access": "public",
16-
"exports": {
17-
".": "./dist/index.js",
18-
"types": "./dist/index.d.ts"
19-
}
25+
"access": "public"
2026
},
2127
"dependencies": {
2228
"nitropack": "^2.11.10"
2329
},
2430
"devDependencies": {
31+
"tsdown": "^0.16.5",
2532
"vite": "^7.1.10"
2633
},
2734
"peerDependencies": {

0 commit comments

Comments
 (0)