eslint-config-reedsy 4.0.0
Install from the command line:
Learn more about npm packages
$ npm install @reedsy/eslint-config-reedsy@4.0.0
Install via package.json:
"@reedsy/eslint-config-reedsy": "4.0.0"
About this version
THIS PACKAGE IS DEPRECATED -- use @reedsy/eslint-plugin
instead
This is a set of common eslint
rules for use across JavaScript projects. Using a common set of rules improves
consistent code style across the organisation; enforces best practices; and can help to avoid common pitfalls and
anti-patterns.
npm i @reedsy/eslint-config-reedsy --save-dev
You'll also need to install the peer dependencies:
npm i eslint eslint-plugin-import --save-dev
Install the package, and then update your .eslintrc
like so:
{
"extends": "@reedsy/eslint-config-reedsy"
}
You can then run eslint
like normal, for example:
eslint src/**/*.js
Think carefully about overriding rules. Overriding will cause our code style to drift between repositories. If a genuine case can be made for changing a rule, it should probably be made in this repository, so that it is shared between all of the other repos that use it.
If you absolutely, positively, must override rules, simply use the normal syntax:
{
"extends": "@reedsy/eslint-config-reedsy",
"rules": {
"no-underscore-dangle": "error"
}
}