Skip to content

Commit 16bc2a2

Browse files
committed
add VSCode settings
1 parent 3e913e5 commit 16bc2a2

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

.vscode/extensions.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"recommendations": [
3+
"dbaeumer.vscode-eslint",
4+
"esbenp.prettier-eslint"
5+
]
6+
}

.vscode/settings.json

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
{
2+
// Enable ESLint
3+
"eslint.enable": true,
4+
// Validate these file types with ESLint
5+
"eslint.validate": [
6+
"javascript",
7+
"javascriptreact",
8+
"typescript",
9+
"typescriptreact"
10+
],
11+
// Format on save
12+
"editor.formatOnSave": true,
13+
// Use ESLint to fix issues on save
14+
"editor.codeActionsOnSave": {
15+
"source.fixAll.eslint": "explicit"
16+
},
17+
// Set default formatter for TypeScript files
18+
"[typescript]": {
19+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
20+
},
21+
"[javascript]": {
22+
"editor.defaultFormatter": "dbaeumer.vscode-eslint"
23+
},
24+
// Optional: Auto-save files
25+
"files.autoSave": "onFocusChange",
26+
// Show ESLint status in the status bar
27+
"eslint.alwaysShowStatus": true
28+
}

0 commit comments

Comments
 (0)