This package includes the shareable ESLint configuration used at Tiller.
Table of Contents
terminal
yarn install -D @tillersystems/eslint-config eslint-config-airbnb-base babel-eslint eslint eslint-plugin-import prettier eslint-plugin-prettier eslint-config-prettier
.eslintrc
{
"extends": "@tillersystems/eslint-config"
}
terminal
yarn install -D @tillersystems/eslint-config eslint-config-airbnb babel-eslint eslint eslint-plugin-import prettier eslint-plugin-jsx-a11y eslint-plugin-react eslint-plugin-prettier eslint-config-prettier
.eslintrc
{
"extends": "@tillersystems/eslint-config/react"
}
terminal
yarn add eslint-config-prettier eslint-plugin-eslint-comments eslint-plugin-import eslint-plugin-jest eslint-plugin-prettier eslint-plugin-promise eslint-config-airbnb-typescript eslint babel-eslint prettier eslint-plugin-react eslint-plugin-jsx-a11y @typescript-eslint/eslint-plugin eslint-import-resolver-typescript --dev
.eslintrc
{
"extends": "@tillersystems/eslint-config/typescript"
}
vscode Inside your Workspace settings in VS Code, you will need to add something like
{
"eslint.workingDirectories": [
{
"directory": "tiller-microservices-javascript",
"changeProcessCWD": true
}
],
"eslint.packageManager": "yarn",
"eslint.format.enable": true,
"eslint.lintTask.enable": true
}
to make it work, depending on how your workspace is setup, this works if your workspace look like:
RootFolder
- tiller-microservices-javascript
- other gits repository
That's it! You can override the settings by editing the .eslintrc
file. Learn more about configuring ESLint on the ESLint website.
Use any ESLint integration and activate "Fix on save" option.
See "Ignoring Files and Directories" on ESLint website.