eslint-plugin-jest-test-each-formatting

1.1.3 • Public • Published

eslint-plugin-jest-test-each-formatting

*(. |_)(test|spec). ESLint plugin that allows automatic formatting of templates when TaggedTemplate format of test.each in (js|jsx|ts|tsx) files.

Publish To npm downloads MIT License

Support Jest *.each

  • describe.each
  • describe.only.each
  • describe.skip.each
  • test.concurrent.each
  • test.concurrent.failing.each
  • test.concurrent.only.each
  • test.concurrent.skip.each
  • test.each
  • test.failing.each
  • test.only.each
  • test.skip.each

Installation

  1. npm install -D eslint
  2. npm install -D eslint-plugin-jest-test-each-formatting
npm install -D eslint
npm install -D eslint-plugin-jest-test-each-formatting

Usage

Add jest-test-each-formatting to the plugins section of your .eslintrc configuration file.

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

Next, configure the rules in the rules section.

{
  "rules": {
    "jest-test-each-formatting/format": ["error", {
      "indent"        : 4
    }]
  }
}

or

You can use recommended to activate the rule.

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

It also supports a strict setting to enable strict rules.

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

Rule Details

Package Sidebar

Install

npm i eslint-plugin-jest-test-each-formatting

Weekly Downloads

12

Version

1.1.3

License

MIT

Unpacked Size

53.2 kB

Total Files

21

Last publish

Collaborators

  • akasaki