@cnblogs/eslint-config-typescript
v1.0.4
Published
Cnblogs prettier config
Downloads
6
Readme
install dependencies
npm i -D eslint prettier @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-plugin-prettier eslint-config-prettier typescript @cnblogs/eslint-config-typescript
extends the configuration
{
"$schema": "https://json.schemastore.org/eslintrc.json",
"root": true,
"extends": ["@cnblogs/typescript"],
// set parser to "@typescript-eslint/parser"
"parser": "@typescript-eslint/parser",
// don't forget to set value of "parserOptions.project"
"parserOptions": {
"project": "tsconfig.json"
// "ecmaVersion": 6,
// "sourceType": "module"
},
"rules": {
// override rules
}
}