A base for projects that use ESLint.
If I should maintain this repo, please ⭐️
DM me on Twitter if you have questions or suggestions.
This package provides a base ESLint config for TypeScript, and a second for TypeScript with React.
In your package.json
file:
TypeScript
This is a generic config for projects that use TypeScript.
{
"eslintConfig": {
"extends": "@autossey/eslint-config"
}
}
Node
The node
config extends the typescript
config and adds rules for Node.js.
{
"eslintConfig": {
"extends": "@autossey/eslint-config/node"
}
}
React
The react
config extends the typescript
config and adds rules for React.
{
"eslintConfig": {
"extends": "@autossey/eslint-config/react"
}
}
Now to run ESLint, run yarn eslint source
or npm run eslint source
.
As this package updates, bug fixes are considered patch updates as usual.
Rule changes are considered minor updates. Rule changes can cause linting errors in your code, If you want to avoid rule changes, you can set your package to use a specific minor version of this package with the ~
operator:
{
"devDependencies": {
"@autossey/eslint-config": "~0.2.0"
}
}
- @types/eslint: TypeScript definitions for eslint
- @typescript-eslint/eslint-plugin: TypeScript plugin for ESLint
- @typescript-eslint/parser: An ESLint custom parser which leverages TypeScript ESTree
- eslint-plugin-i: A fork of
eslint-plugin-import
usingget-tsconfig
to replacetsconfig-paths
and heavytypescript
under the hood. - eslint-plugin-json: eslint plugin for JSON files
- eslint-plugin-n: Additional ESLint's rules for Node.js
- eslint-plugin-react: React specific linting rules for ESLint
- eslint-plugin-react-hooks: ESLint rules for React Hooks
- eslint: An AST-based pattern checker for JavaScript.
- @autossey/tsconfig: A collection of base TSConfigs for various types of projects.
- eslint: An AST-based pattern checker for JavaScript.
MIT - MIT License