Skip to content

Commit 496aca4

Browse files
authored
ci: move the type-checking out of the build process (#393)
ci: move the type-checking out of the build process
1 parent bb40c12 commit 496aca4

File tree

2 files changed

+14
-8
lines changed

2 files changed

+14
-8
lines changed

.github/workflows/pr.yml

+4
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ jobs:
3232
- name: Install dependencies
3333
run: pnpm install --frozen-lockfile
3434

35+
# This step runs the ci script for type-level errors.
36+
- name: Run the tsc compiler to check for type-level errors
37+
run: pnpm ci:typecheck
38+
3539
# This step runs the ci script for linting to check for linting errors.
3640
- name: Run the linter to check for linting errors
3741
run: pnpm ci:lint

package.json

+10-8
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,21 @@
44
"private": true,
55
"type": "module",
66
"scripts": {
7-
"start": "vite preview --host localhost --port 3000",
7+
"build": "pnpm run clean && pnpm run build:code",
8+
"build:code": "vite build",
9+
"ci:format": "pnpm run format",
10+
"ci:lint": "pnpm run lint",
11+
"ci:typecheck": "pnpm run typecheck",
12+
"clean": "rimraf ./dist && rimraf ./coverage",
813
"dev": "vite",
9-
"lint": "eslint --max-warnings 0 .",
10-
"lint:fix": "eslint --fix --max-warnings 0 .",
1114
"format": "prettier --check './src/**/*.{js,jsx,ts,tsx,css,md,json}' --config './prettier.config.cjs'",
1215
"format:fix": "prettier --write './src/**/*.{js,jsx,ts,tsx,css,md,json}' --config './prettier.config.cjs'",
13-
"clean": "rimraf ./dist && rimraf ./coverage",
14-
"build:code": "tsc && vite build",
15-
"build": "pnpm run clean && pnpm run lint && pnpm run build:code",
16+
"lint": "eslint --max-warnings 0 .",
17+
"lint:fix": "eslint --fix --max-warnings 0 .",
1618
"postbuild": "node ./postbuild.cjs",
1719
"preview": "vite preview --port 3000",
18-
"ci:lint": "pnpm run lint",
19-
"ci:format": "pnpm run format"
20+
"start": "vite preview --host localhost --port 3000",
21+
"typecheck": "tsc --noEmit"
2022
},
2123
"dependencies": {
2224
"@dnd-kit/core": "^6.1.0",

0 commit comments

Comments
 (0)