Skip to content

Commit e08a049

Browse files
authored
Biome (#51)
Installed biome & husky
1 parent 1b42190 commit e08a049

30 files changed

+627
-2251
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
name: Build
2-
on:
3-
pull_request:
4-
types: [ opened, edited, reopened, review_requested ]
5-
branches: [ main ]
2+
on: pull_request
63
permissions:
74
contents: write
85
jobs:

.husky/pre-commit

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/usr/bin/env sh
2+
3+
cd frontend && npm run lint

.husky/pre-push

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
#!/usr/bin/env sh
2+
3+
cd frontend && npm run prepush
4+
5+
if [ $(git status --porcelain=v1 2>/dev/null | wc -l) -ne 0 ]; then
6+
echo "Warning, you have uncommitted changes, are you sure you want to push? (if so use the --no-verify flag)"
7+
exit 1
8+
fi

frontend/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ pnpm-debug.log*
88
lerna-debug.log*
99

1010
node_modules
11+
dist
1112
dist-ssr
1213
*.local
1314

frontend/README.md

Lines changed: 0 additions & 50 deletions
This file was deleted.

frontend/biome.json

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
{
2+
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json",
3+
"organizeImports": {
4+
"enabled": true
5+
},
6+
"formatter": {
7+
"enabled": true,
8+
"formatWithErrors": false,
9+
"indentStyle": "space",
10+
"indentWidth": 2,
11+
"lineWidth": 160
12+
},
13+
"javascript": {
14+
"formatter": {
15+
"quoteStyle": "single",
16+
"quoteProperties": "asNeeded",
17+
"semicolons": "asNeeded",
18+
"arrowParentheses": "always"
19+
}
20+
},
21+
"vcs": {
22+
"useIgnoreFile": true,
23+
"enabled": true,
24+
"clientKind": "git"
25+
},
26+
"json": {
27+
"formatter": {
28+
"enabled": true
29+
}
30+
},
31+
"linter": {
32+
"enabled": true,
33+
"rules": {
34+
"recommended": true,
35+
"correctness": {
36+
"noUnusedImports": "error",
37+
"noUnusedVariables": "error",
38+
"useExhaustiveDependencies": "off"
39+
},
40+
"complexity": {
41+
"useSimplifiedLogicExpression": "off",
42+
"noStaticOnlyClass": "off"
43+
},
44+
"suspicious": {
45+
"noConfusingVoidType": "off",
46+
"noArrayIndexKey": "off"
47+
},
48+
"style": {
49+
"useExportType": "error",
50+
"noUselessElse": "off",
51+
"useNodejsImportProtocol": "error",
52+
"useImportType": "error"
53+
},
54+
"a11y": {
55+
"useKeyWithClickEvents": "off",
56+
"useValidAnchor": "off"
57+
},
58+
"security": {
59+
"noDangerouslySetInnerHtml": "off",
60+
"noGlobalEval": "off"
61+
},
62+
"performance": {
63+
"noAccumulatingSpread": "off"
64+
}
65+
}
66+
},
67+
"files": {
68+
"ignoreUnknown": true,
69+
"ignore": ["node_modules/*", "dist/*"]
70+
}
71+
}

frontend/components.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@
1818
"hooks": "@/hooks"
1919
},
2020
"iconLibrary": "lucide"
21-
}
21+
}

frontend/eslint.config.js

Lines changed: 0 additions & 28 deletions
This file was deleted.

0 commit comments

Comments
 (0)