@affinidi/eslint-config
v2.0.0-beta.0
Published
Affinidi's Base ESLint Configuration
Downloads
48
Keywords
Readme
ESLint Config
Affinidi's Base ESLint Configuration
Installation
npm install --save-dev @affinidi/eslint-config
Usage
// .eslintrc.js
module.exports = {
extends: ['@affinidi/eslint-config'],
parserOptions: {
project: './tsconfig.eslint.json',
},
}
It is reccommended that you have a separate tsconfig.eslint.json
file that extends from your existing tsconfig.json
file. This file will add .eslintrc.js
to the "includes"
property.
{
"extends": "./tsconfig.json",
"include": ["...", ".eslintrc.js"]
}
VS Code + Monorepos
VS Code's ESLint extension requires an additional setting to properly detect ESLint versions/installs/root paths. In a typical mono repo you can do the following:
"eslint.workingDirectories": [
{
"pattern": "./packages/*"
}
]
For more details check out the extention's docs.