2.0.9 • Published 17 days ago
@karasushin/eslint-config v2.0.9
@karasushin/eslint-config
English / 简体中文
用法
安装
pnpm add -D eslint @karasushin/eslint-config
配置
在你的项目下创建一个 eslint.config.js
import { karasu } from '@karasushin/eslint'
export default karasu()
你也可以进行一些自定义配置
export default karasu({
typescript: true, // default true
react: true, // default false
markdown: true, // default false
})
添加 lint 脚本
添加以下内容到 package.json
{
"scripts": {
"lint": "eslint .",
"lint:fix": "eslint . --fix"
}
}
配置 VSCode
编辑 settings.json
{
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true,
"source.organizeImports": "never"
},
"eslint.experimental.useFlatConfig": true,
"eslint.format.enable": true,
"eslint.validate": [
"html",
"javascript",
"javascriptreact",
"json",
"jsonc"
"markdown",
"typescript",
"typescriptreact",
]
}
2.0.9
17 days ago
2.0.8
2 months ago
2.0.7
2 months ago
2.0.6
3 months ago
2.0.3
5 months ago
2.0.2
5 months ago
2.0.5
5 months ago
2.0.4
5 months ago
2.0.1
5 months ago
2.0.0
5 months ago
1.2.0
9 months ago
1.1.1
10 months ago
1.0.2
10 months ago
1.1.0
10 months ago
1.0.1
10 months ago
1.0.0
10 months ago
1.3.5
6 months ago
1.3.4
9 months ago
1.5.1
6 months ago
1.3.3
9 months ago
1.5.0
6 months ago
1.3.2
9 months ago
1.4.0
6 months ago
1.3.1
9 months ago
1.2.2
9 months ago
1.3.0
9 months ago
1.2.1
9 months ago
1.0.3
10 months ago
0.2.1
1 year ago
0.2.0
1 year ago
0.1.10
2 years ago
0.1.8
2 years ago
0.1.7
2 years ago
0.1.9
2 years ago
0.1.6
2 years ago
0.1.5
2 years ago
0.1.4
2 years ago
0.1.3
2 years ago
0.1.2
2 years ago
0.1.0
2 years ago