@lego/eslint-config-jest
v7.1.2
Published
LEGO shareable eslint config for testing js/ts projects
Downloads
4
Readme
@lego/eslint-config-jest
Purpose
This is an opinionated all-round configuration.
Installation
Install this config package:
$ npm i -D @lego/eslint-config-jest
Usage
Extend your eslint.json
, and make sure @lego/eslint-config
has been added:
{
"extends": ["@lego/eslint-config", "@lego/eslint-config-jest"]
}
Note: if you want to use TypeScript don't use
@lego/eslint-config
, use@lego/eslint-config-typescript
instead.
Overriding Rules
With the above eslint.json
configuration example, you can still use or override already defined
rules as such:
{
"extends": "@lego/eslint-config",
"rules": {
"camelcase": "warn"
}
}
It's recommended to inspect the defined rule's configurations where the reasoning for the configuration lives. If a configuration could benefit more than just the project you're working on, feel free to create a pull request.