3.1.0 • Published 4 years ago

eslint-plugin-jest-formatting v3.1.0

Weekly downloads
173,386
License
MIT
Repository
github
Last release
4 years ago

CircleCI npm monthly downloads

eslint-plugin-jest-formatting

This package provides ESLint rules for jest test suites.

This project aims to provide formatting rules (auto-fixable where possible) to ensure consistency and readability in jest test suites.

Like this plugin? Say thanks with a ⭐️

Note: The master version may not be the version deployed to npm. Please treat https://www.npmjs.com/package/eslint-plugin-jest-formatting as the cannonical source for docs.

Installation

You'll first need to install ESLint:

$ yarn add eslint --dev

Next, install eslint-plugin-jest-formatting:

$ yarn add eslint-plugin-jest-formatting --dev

Note: If you installed ESLint globally (using the -g flag) then you must also install eslint-plugin-jest-formatting globally.

Usage

Add jest-formatting to the plugins section of your .eslintrc configuration file. You can omit the eslint-plugin- prefix:

{
  "plugins": ["jest-formatting"]
}

Then configure the rules you want to use under the rules section.

{
  "rules": {
    "jest-formatting/padding-around-describe-blocks": 2,
    "jest-formatting/padding-around-test-blocks": 2
  }
}

or

You can use our "recommended" settings which enables most of the rules for you

{
  "extends": ["plugin:jest-formatting/recommended"]
}

We also support a "strict" settings which enabled all of the rules for you

{
  "extends": ["plugin:jest-formatting/strict"]
}

Rule Documentation

Related Projects

eslint-plugin-jest

This provides an extensive set of jest eslint rules

https://github.com/jest-community/eslint-plugin-jest

eslint-config-innovorder@infinitebrahmanuniverse/nolb-eslint-plugin-jeslint-config-equips-tseslint-config-tyler-zeyeslint-tyler-zey@everything-registry/sub-chunk-1612eslint-config-wishketvoluptatesporrolint-fn@waldronmatt/eslint-config@washingtondc/eslint@web-configs/eslint-plugin@wayofdev/eslint-config@wayofdev/eslint-config-bases@wistia/eslint-config@wishket/eslint-config-wishket@wyattades/eslint-config@uniqorg/eslint-plugin@toptal/davinci-syntax@tinkin/eslint-config@vgd/eslint-config-personal@valian/eslint-config@utima/eslint-config@voltiso/config.eslint@voltiso/eslint-config@voltiso/eslint-config-fast@zattoo/eslint-config@terminal-nerds/eslint-config@hannohealth/eslint-config@hannoeru/eslint-plugin@adbayb/eslint-config@liveauctioneers/eslint-config-hammer-ui@lmc-eu/eslint-config-jest@localyze-pluto/eslint-config@lottiefiles/eslint-plugin@linters/eslint-config-jest@lukas.skamarakas/eslint-plugin@spec-validator/qapatchedreactjs-zero@pandora-box/eslint-config-jest@okize/eslint-config@ochnerd/eslint-plugin@hybrbase-front/eslint-config@hybrbase-staxomni/eslint-config@hybrbase/eslint-config@gathermade/eslint-config@getracker/eslint-config@hendacorp/eslint-plugin@faustbrian/stdlint@fe-boilerplate/eslint-config@heed/eslint-config-heed@flex-development/eslint-config@flynoe/eslint-config-basic@emiolo/design-patterns@emiolo/eslint-config@emiolo/thalamus-express@fullstacksjs/eslint-config@functorfactory/eslint-config@plesk/eslint-config@shelf/eslint-config@shopify/eslint-plugin@techmmunity/eslint-config@spotmonkeystudios/eslint-configeslint-config-lukemoraleseslint-config-r1ckyrockzeslint-plugin-dwceslint-config-innovorder-v2eslint-config-ksv741eslint-config-okizeeslint-config-rocketeslint-config-timetreeeslint-config-tinkineslint-config-nhuesmann-ts-reacteslint-config-noamkadosheslint-config-simplymadeappseslint-config-tunde-dev-reacteslint-config-strict-modeeslint-config-suiyobieslint-config-steeleslint-config-skyscannereslint-config-superology-vueeslint-config-brandingbrandeslint-config-altnexteslint-config-codecogeslint-config-eloquenceeslint-config-eschadeslint-config-7sne-eslinteslint-config-backendeslint-config-baseseslint-config-beslogiceslint-config-cortexeslint-config-current-thingeslint-config-d2-softwareeslint-config-chanw9503eslint-config-maniaeslint-config-hardcoreeslint-config-ibbizeslint-config-intenseeslint-config-ndpkg
3.1.0

4 years ago

3.0.0

5 years ago

2.0.1

5 years ago

2.0.0

5 years ago

1.2.0

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago

0.1.0

6 years ago

0.0.11

6 years ago

0.0.10

6 years ago

0.0.9

7 years ago

0.0.8

7 years ago

0.0.7

7 years ago

0.0.6

7 years ago

0.0.5

7 years ago

0.0.4

7 years ago

0.0.1

7 years ago

0.0.0

7 years ago