Shareable TypeScript config to be used with ESLint
npx install-peerdeps --dev @nielse63/tsconfig-eslint
Create a file called tsconfig.eslint.json
in your project root with the following content:
{
"extends": "@nielse63/tsconfig-eslint",
// you can customize your include and exclude values
"include": ["**/*.ts", "**/*.js", ".*.js", ".bin/**/*"],
"exclude": ["**/node_modules/**", "**/dist/**"],
}
Update your .eslintrc.js
file:
module.exports = {
parser: '@typescript-eslint/parser',
parserOptions: {
project: ['./tsconfig.eslint.json'],
},
};