Skip to content

Commit ac3b86c

Browse files
committed
chore: setup prettier and git hooks
1 parent 86fe79f commit ac3b86c

5 files changed

Lines changed: 5223 additions & 1572 deletions

File tree

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,3 +36,5 @@ yarn-error.log*
3636
.vercel
3737
.vscode
3838
.env*.local
39+
40+
tsconfig.tsbuildinfo

.husky/pre-commit

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pnpm exec lint-staged

.lintstagedrc.mjs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
export default {
2+
'*': 'prettier --ignore-unknown --write',
3+
'**/*.{js,jsx,ts,tsx}': 'pnpm lint:fix',
4+
'**/*.{ts,tsx}': () => 'pnpm type-check',
5+
};

package.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@
1515
"db:push": "drizzle-kit push",
1616
"db:pull": "drizzle-kit pull",
1717
"db:check": "drizzle-kit check",
18-
"db:up": "drizzle-kit up"
18+
"db:up": "drizzle-kit up",
19+
"prepare": "husky && husky install",
20+
"type-check": "tsc --noEmit"
1921
},
2022
"dependencies": {
2123
"@ai-sdk/fireworks": "^0.1.8",
@@ -104,6 +106,8 @@
104106
"eslint-config-prettier": "^9.1.0",
105107
"eslint-import-resolver-typescript": "^3.6.3",
106108
"eslint-plugin-tailwindcss": "^3.17.5",
109+
"husky": "^9.1.7",
110+
"lint-staged": "^15.4.3",
107111
"postcss": "^8",
108112
"tailwindcss": "^3.4.1",
109113
"tsx": "^4.19.1",

0 commit comments

Comments
 (0)