Skip to content

Commit f56e4b5

Browse files
committed
chore: 🤖 add prettier and lint-staged
1 parent b86a59b commit f56e4b5

5 files changed

+609
-2
lines changed

.prettierrc

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"printWidth": 80,
3+
"proseWrap": "never",
4+
"semi": true,
5+
"singleQuote": true,
6+
"trailingComma": "all"
7+
}

husky.config.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
module.exports = {
22
hooks: {
3-
"prepare-commit-msg": "exec < /dev/tty && git cz --hook || true",
3+
'pre-commit': 'lint-staged',
4+
'prepare-commit-msg': 'exec < /dev/tty && git cz --hook || true',
45
},
56
};

lint-staged.config.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
'*.{js,jsx,ts,tsx,css,md}': 'prettier --write',
3+
};

0 commit comments

Comments
 (0)