- Add this to devDependencies
$ npm i -D @bhws/eslint-config
# or
$ yarn add -D @bhws/eslint-config- Install
eslintif not already present locally or globally
$ npm i -D eslint
# or
$ yarn add -D eslint-
Create a
.eslintrcfile -
Extend the config (you can use just the scope name as ESLint will assume the
eslint-configprefix):
{
"extends": [
"bhws"
]
}A full example .eslintrc for a project with babel support:
Dont forget to
npm i -D babel-eslintoryarn add -D babel-eslint
{
"root": true,
"parserOptions": {
"parser": "babel-eslint",
"sourceType": "module"
},
"extends": [
"bhws"
]
}Setup inspired by @nuxtjs/eslint-config & eslint-config-standard