Skip to content

Commit f60f71d

Browse files
authored
ci: setup type-checking on PRs (#90)
2 parents a7e6a5a + e982943 commit f60f71d

File tree

3 files changed

+30
-5
lines changed

3 files changed

+30
-5
lines changed

.github/workflows/lint.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
lint:
11+
name: Lint
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v3
15+
- uses: pnpm/action-setup@v2
16+
- uses: actions/setup-node@v3
17+
with:
18+
node-version: 18
19+
cache: "pnpm"
20+
- if: ${{ steps.cache-node.outputs.cache-hit != 'true' }}
21+
run: pnpm install
22+
- run: pnpm build
23+
- run: pnpm type-check

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
"format": "pnpm run format:code",
1313
"format:code": "prettier -w . --cache",
1414
"format:imports": "organize-imports-cli ./packages/*/tsconfig.json",
15+
"type-check": "tsc",
1516
"ci:version": "changeset version && pnpm install --no-frozen-lockfile",
1617
"ci:publish": "changeset publish",
1718
"ci:format": "pnpm run format:imports && pnpm run format:code"

tsconfig.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
{
22
"compilerOptions": {
3+
"noEmit": true,
34
"module": "ESNext",
45
"target": "ESNext",
5-
"declaration": true,
66
"moduleResolution": "node",
7-
"emitDeclarationOnly": true,
87
"strict": true,
98
"esModuleInterop": true,
109
"forceConsistentCasingInFileNames": true,
11-
"allowJs": true,
12-
"types": ["node"]
13-
}
10+
"skipLibCheck": true,
11+
},
12+
"include": [
13+
"packages"
14+
]
1415
}

0 commit comments

Comments
 (0)