1.0.26 • Published 3 months ago
@brucesong/eslint-config-astro v1.0.26
@brucesong/eslint-config-astro
Features
- Suitable for Astro + React + TypeScript + TailwindCSS projects
- Based on Airbnb JavaScript Style
import
、export
auto sort- TailwindCSS class name auto sort, merge
- Resolving conflicts between
ESLint
andPrettier
- Support defining
ESLINT_TSCONFIG
in the env to specify thetsconfig.json
file path used by ESLint - Auto check
tsconfig.json
、tsconfig.eslint.json
file in the project root directory
About checking the priority of tsconfig
- If
ESLINT_TSCONFIG
is defined in the env, use the path specified in the env - If
tsconfig.eslint.json
exists in the project root directory, use this file - If
tsconfig.json
exists in the project root directory, use this file
Usage
Install
pnpm add -D eslint @brucesong/eslint-config-astro
Config .eslintrc.json
{
"extends": "@brucesong/eslint-config-astro"
}
Add script for package.json
{
"scripts": {
"lint": "eslint .",
"lint:fix": "eslint . --fix"
}
}
Config VSCode auto fix
{
"editor.codeActionsOnSave": {
"source.fixAll": false,
"source.fixAll.eslint": true,
"source.organizeImports": false
}
}
License
MIT License © 2023 Bruce Song
1.0.26
3 months ago
1.0.25
4 months ago
1.0.24
5 months ago
1.0.23
5 months ago
1.0.22
6 months ago
1.0.21
6 months ago
1.0.20
6 months ago
1.0.19
6 months ago
1.0.18
6 months ago
1.0.17
7 months ago
1.0.16
7 months ago
1.0.15
7 months ago
1.0.14
8 months ago
1.0.13
8 months ago
1.0.12
8 months ago
1.0.11
8 months ago
1.0.10
9 months ago
1.0.9
9 months ago
1.0.8
9 months ago
1.0.7
9 months ago
1.0.6
9 months ago
1.0.5
9 months ago
1.0.4
9 months ago
1.0.3
9 months ago
1.0.2
9 months ago
1.0.1
9 months ago
1.0.0
9 months ago
0.0.11
9 months ago
0.0.10
9 months ago
0.0.9
9 months ago
0.0.8
9 months ago
0.0.7
9 months ago
0.0.6
9 months ago
0.0.5
9 months ago
0.0.4
9 months ago
0.0.3
9 months ago
0.0.2
9 months ago
0.0.1
9 months ago