{"name":"eslint-plugin-jest-dom","version":"1.2.0","description":"lint rules for use with jest-dom","keywords":["eslint","eslintplugin","eslint-plugin"],"author":{"name":"Ben Monro"},"main":"lib/index.js","scripts":{"lint":"eslint .","test":"jest","generate-readme-table":"node build/generate-readme-table.js"},"dependencies":{"requireindex":"~1.2.0"},"devDependencies":{"eslint":"^6.6.0","eslint-plugin-eslint-plugin":"^2.1.0","eslint-plugin-prettier":"^3.1.1","eslint-plugin-standard":"^4.0.1","jest":"^24.9.0","kcd-scripts":"^1.9.0","prettier":"^1.18.2"},"engines":{"node":">=0.10.0"},"license":"ISC","gitHead":"18b42582c13b42d6d19bd0a4786abc2a1cf8ef00","_id":"eslint-plugin-jest-dom@1.2.0","_npmVersion":"6.4.1","_nodeVersion":"8.16.2","_npmUser":{"name":"benmonro","email":"ben.monro@gmail.com"},"dist":{"integrity":"sha512-ozt3F6eRsjFw1EaHNYpHNUIRmvz3j/sZVXni96zTEUyaX3rmWyBSglOH93VBdYjR24bB9Bkx+Ve5wZM648s4Ig==","shasum":"f483812a13b8180f9e6bea1eeb19115d19abaf55","tarball":"http://registry-npm.ywwl.com/eslint-plugin-jest-dom/download/eslint-plugin-jest-dom-1.2.0.tgz","fileCount":24,"unpackedSize":41648,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJd0csRCRA9TVsSAnZWagAAjb4P/Asp8nY1h+1JJlgkiroq\nfYsLCm+ttDiImofeoM/GJR6WyYJjxY4y6twt632IEp26ypIZ4BATbP5lCCe1\nJKBkWl3p5rh/4XGbGIGf8YeVtu+OtdmlrKEuPdtEXGKjja+fdvGCDlUpsYzl\nCDdEgcTDe7G0FJAGTr+xScBKTF6t/JXLU9DUHnzSnKvadQ74PAZQCqWmTtWK\nNUFIdHbuayUWlErWAmTXEyTZbEy8Zh77QODsLu1mj3D1r9CLztQ62ggCBmDX\nT3HOFnpxS+jD5DyQ0zigeCIZDMuF7hB4FXATxLYq+HYTvePvzw9tYjUAc/6P\nQJo4WY8/ZkCWTXa8TMVt/vmTq/bo9om0hUk2xdJdK87+ULqj88NQcrhGKdaJ\nFtY1vhPkezmfzuT1w59hdI4lReYxWxA5EIPNhxcU7YsNAWmMn0j3Vp8AJSOt\nI26rqdjG8lBHMGqExI2o2zxVM0vj0sgS2hGgvcVehvSowhNFZgt8qee3NhCH\nvYX6CJz1BURmMhZ61F6B2im4god9Bwt7N/fuI/twqG7OXZdrte6QcUTLXdnH\npfDdDzlxDEm0AFr2qz/1wdi6STNPoUqwOIGDyHDlB6beVlLGRN3ALg1EV1bP\nEyoAc99n2ArOnQeMO38CtfktfPlhKSAa+53nTk4/FHY4UUg5PYTvJp7gYR8V\nA8sl\r\n=6nYL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIF5KP5YdxpygWm/MMVxJoMfPaSPYSGzWgzAwyaqmU66XAiALRZr8VMGXZBY+nzsS9trwyHHsWupVwjM3NxlQAg26mA=="}],"size":8110,"noattachment":false,"key":"/eslint-plugin-jest-dom/-/eslint-plugin-jest-dom-1.2.0.tgz"},"maintainers":[{"name":"benmonro","email":"ben.monro@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/eslint-plugin-jest-dom_1.2.0_1574030097525_0.8519734114255668"},"_hasShrinkwrap":false,"readme":"<div align=\"center\">\n<h1>eslint-plugin-jest-dom</h1>\n\n<p>ESLint plugin to follow best practices and anticipate common mistakes when writing tests with jest-dom.</p>\n</div>\n\n---\n\n<!-- prettier-ignore-start -->\n[![Build Status][build-badge]][build]\n[![Code Coverage][coverage-badge]][coverage]\n[![version][version-badge]][package]\n[![downloads][downloads-badge]][npmtrends]\n[![MIT License][license-badge]][license]\n[![All Contributors][all-contributors-badge]](#contributors-)\n[![PRs Welcome][prs-badge]][prs]\n[![Code of Conduct][coc-badge]][coc]\n<!-- prettier-ignore-end -->\n\n## Table of Contents\n\n<!-- START doctoc generated TOC please keep comment here to allow auto update -->\n<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->\n\n- [Installation](#installation)\n- [Usage](#usage)\n- [Recommended Configuration](#recommended-configuration)\n- [Supported Rules](#supported-rules)\n- [Issues](#issues)\n  - [🐛 Bugs](#-bugs)\n  - [💡 Feature Requests](#-feature-requests)\n- [Contributors ✨](#contributors-)\n- [LICENSE](#license)\n\n<!-- END doctoc generated TOC please keep comment here to allow auto update -->\n\n## Installation\n\nThis module is distributed via [npm][npm] which is bundled with [node][node] and\nshould be installed as one of your project's `devDependencies`:\n\n```\nnpm install --save-dev eslint-plugin-jest-dom\n```\n\nThis library has a required `peerDependencies` listing for [`ESLint`](https://eslint.org/).\n\n## Usage\n\n> [!NOTE]\n>\n> `eslint.config.js` is supported, though most of the plugin documentation still\n> currently uses `.eslintrc` syntax; compatible versions of configs are available\n> prefixed with `flat/` and may be subject to small breaking changes while ESLint\n> v9 is being finalized.\n>\n> Refer to the\n> [ESLint documentation on the new configuration file format](https://eslint.org/docs/latest/use/configure/configuration-files-new)\n> for more.\n\nAdd `jest-dom` to the plugins section of your `.eslintrc.js` configuration file.\nYou can omit the `eslint-plugin-` prefix:\n\n```javascript\nmodule.exports = {\n  plugins: [\"jest-dom\"],\n  rules: {\n    // your configuration\n  },\n};\n```\n\nThen configure the rules you want to use under the rules section.\n\n```javascript\nmodule.exports = {\n  rules: {\n    \"jest-dom/prefer-checked\": \"error\",\n    \"jest-dom/prefer-enabled-disabled\": \"error\",\n    \"jest-dom/prefer-required\": \"error\",\n    \"jest-dom/prefer-to-have-attribute\": \"error\",\n  },\n};\n```\n\n## Recommended Configuration\n\nThis plugin exports a recommended configuration that enforces good `jest-dom`\npractices _(you can find more info about enabled rules in\n[Supported Rules section](#supported-rules))_.\n\nTo enable this configuration with `.eslintrc`, use the `extends` property:\n\n```javascript\nmodule.exports = {\n  extends: \"plugin:jest-dom/recommended\",\n  rules: {\n    // your configuration\n  },\n};\n```\n\nTo enable this configuration with `eslint.config.js`, use\n`jestDom.configs['flat/recommended']`:\n\n```javascript\nmodule.exports = [\n  {\n    files: [\n      /* glob matching your test files */\n    ],\n    ...require(\"eslint-plugin-jest-dom\").configs[\"flat/recommended\"],\n  },\n];\n```\n\n## Supported Rules\n\n<!-- begin auto-generated rules list -->\n\n💼 Configurations enabled in.\\\n✅ Set in the `recommended` configuration.\\\n🔧 Automatically fixable by the [`--fix` CLI option](https://eslint.org/docs/user-guide/command-line-interface#--fix).\\\n💡 Manually fixable by [editor suggestions](https://eslint.org/docs/latest/use/core-concepts#rule-suggestions).\n\n| Name                                                                     | Description                                                           | 💼 | 🔧 | 💡 |\n| :----------------------------------------------------------------------- | :-------------------------------------------------------------------- | :- | :- | :- |\n| [prefer-checked](docs/rules/prefer-checked.md)                           | prefer toBeChecked over checking attributes                           | ✅  | 🔧 |    |\n| [prefer-empty](docs/rules/prefer-empty.md)                               | Prefer toBeEmpty over checking innerHTML                              | ✅  | 🔧 |    |\n| [prefer-enabled-disabled](docs/rules/prefer-enabled-disabled.md)         | prefer toBeDisabled or toBeEnabled over checking attributes           | ✅  | 🔧 |    |\n| [prefer-focus](docs/rules/prefer-focus.md)                               | prefer toHaveFocus over checking document.activeElement               | ✅  | 🔧 |    |\n| [prefer-in-document](docs/rules/prefer-in-document.md)                   | Prefer .toBeInTheDocument() for asserting the existence of a DOM node | ✅  | 🔧 | 💡 |\n| [prefer-required](docs/rules/prefer-required.md)                         | prefer toBeRequired over checking properties                          | ✅  | 🔧 |    |\n| [prefer-to-have-attribute](docs/rules/prefer-to-have-attribute.md)       | prefer toHaveAttribute over checking  getAttribute/hasAttribute       | ✅  | 🔧 |    |\n| [prefer-to-have-class](docs/rules/prefer-to-have-class.md)               | prefer toHaveClass over checking element className                    | ✅  | 🔧 |    |\n| [prefer-to-have-style](docs/rules/prefer-to-have-style.md)               | prefer toHaveStyle over checking element style                        | ✅  | 🔧 |    |\n| [prefer-to-have-text-content](docs/rules/prefer-to-have-text-content.md) | Prefer toHaveTextContent over checking element.textContent            | ✅  | 🔧 |    |\n| [prefer-to-have-value](docs/rules/prefer-to-have-value.md)               | prefer toHaveValue over checking element.value                        | ✅  | 🔧 |    |\n\n<!-- end auto-generated rules list -->\n\n## Issues\n\n_Looking to contribute? Look for the [Good First Issue][good-first-issue]\nlabel._\n\n### 🐛 Bugs\n\nPlease file an issue for bugs, missing documentation, or unexpected behavior.\n\n[**See Bugs**][bugs]\n\n### 💡 Feature Requests\n\nPlease file an issue to suggest new features. Vote on feature requests by adding\na 👍. This helps maintainers prioritize what to work on.\n\n[**See Feature Requests**][requests]\n\n## Contributors ✨\n\nThanks goes to these people ([emoji key][emojis]):\n\n<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->\n<!-- prettier-ignore-start -->\n<!-- markdownlint-disable -->\n<table>\n  <tr>\n    <td align=\"center\"><a href=\"https://github.com/benmonro\"><img src=\"https://avatars3.githubusercontent.com/u/399236?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Ben Monro</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=benmonro\" title=\"Documentation\">📖</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=benmonro\" title=\"Code\">💻</a> <a href=\"#example-benmonro\" title=\"Examples\">💡</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=benmonro\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"https://nickmccurdy.com/\"><img src=\"https://avatars0.githubusercontent.com/u/927220?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Nick McCurdy</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=nickmccurdy\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=nickmccurdy\" title=\"Documentation\">📖</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=nickmccurdy\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"https://twitter.com/gnapse\"><img src=\"https://avatars0.githubusercontent.com/u/15199?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Ernesto García</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=gnapse\" title=\"Documentation\">📖</a></td>\n    <td align=\"center\"><a href=\"https://chriscolborne.com\"><img src=\"https://avatars2.githubusercontent.com/u/101371?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Chris Colborne</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=zorfling\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=zorfling\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"https://michaeldeboey.be\"><img src=\"https://avatars3.githubusercontent.com/u/6643991?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Michaël De Boey</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=MichaelDeBoey\" title=\"Code\">💻</a></td>\n    <td align=\"center\"><a href=\"http://gerritalex.de\"><img src=\"https://avatars1.githubusercontent.com/u/29307652?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Gerrit Alex</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=ljosberinn\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=ljosberinn\" title=\"Tests\">⚠️</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=ljosberinn\" title=\"Documentation\">📖</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3Aljosberinn\" title=\"Bug reports\">🐛</a></td>\n    <td align=\"center\"><a href=\"http://ololos.space/\"><img src=\"https://avatars1.githubusercontent.com/u/3940079?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Andrey Los</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3ARIP21\" title=\"Bug reports\">🐛</a></td>\n  </tr>\n  <tr>\n    <td align=\"center\"><a href=\"https://skovy.dev\"><img src=\"https://avatars1.githubusercontent.com/u/5247455?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Spencer Miskoviak</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=skovy\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=skovy\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"https://github.com/atsikov\"><img src=\"https://avatars3.githubusercontent.com/u/1422928?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Aleksei Tsikov</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3Aatsikov\" title=\"Bug reports\">🐛</a></td>\n    <td align=\"center\"><a href=\"https://mario.dev\"><img src=\"https://avatars1.githubusercontent.com/u/2677072?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Mario Beltrán Alarcón</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=Belco90\" title=\"Documentation\">📖</a></td>\n    <td align=\"center\"><a href=\"https://codepen.io/ariperkkio/\"><img src=\"https://avatars2.githubusercontent.com/u/14806298?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Ari Perkkiö</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3AAriPerkkio\" title=\"Bug reports\">🐛</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=AriPerkkio\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=AriPerkkio\" title=\"Tests\">⚠️</a></td>\n    <td align=\"center\"><a href=\"http://www.antn.se\"><img src=\"https://avatars0.githubusercontent.com/u/785676?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Anton Niklasson</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=AntonNiklasson\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=AntonNiklasson\" title=\"Tests\">⚠️</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=AntonNiklasson\" title=\"Documentation\">📖</a></td>\n    <td align=\"center\"><a href=\"http://juzerzarif.com\"><img src=\"https://avatars3.githubusercontent.com/u/22772637?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Juzer Zarif</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=juzerzarif\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=juzerzarif\" title=\"Tests\">⚠️</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3Ajuzerzarif\" title=\"Bug reports\">🐛</a></td>\n    <td align=\"center\"><a href=\"http://everlong.org/\"><img src=\"https://avatars.githubusercontent.com/u/454175?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Julien Wajsberg</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=julienw\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=julienw\" title=\"Tests\">⚠️</a></td>\n  </tr>\n  <tr>\n    <td align=\"center\"><a href=\"https://github.com/G-Rath\"><img src=\"https://avatars.githubusercontent.com/u/3151613?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Gareth Jones</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=G-Rath\" title=\"Tests\">⚠️</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=G-Rath\" title=\"Code\">💻</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3AG-Rath\" title=\"Bug reports\">🐛</a></td>\n    <td align=\"center\"><a href=\"https://github.com/huyenltnguyen\"><img src=\"https://avatars.githubusercontent.com/u/25715018?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Huyen Nguyen</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=huyenltnguyen\" title=\"Documentation\">📖</a></td>\n    <td align=\"center\"><a href=\"https://github.com/mdotwills\"><img src=\"https://avatars.githubusercontent.com/u/5505611?v=4?s=100\" width=\"100px;\" alt=\"\"/><br /><sub><b>Matthew</b></sub></a><br /><a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/issues?q=author%3Amdotwills\" title=\"Bug reports\">🐛</a> <a href=\"https://github.com/testing-library/eslint-plugin-jest-dom/commits?author=mdotwills\" title=\"Code\">💻</a></td>\n  </tr>\n</table>\n\n<!-- markdownlint-restore -->\n<!-- prettier-ignore-end -->\n\n<!-- ALL-CONTRIBUTORS-LIST:END -->\n\nThis project follows the [all-contributors][all-contributors] specification.\nContributions of any kind welcome!\n\n## LICENSE\n\nMIT\n\n<!-- prettier-ignore-start -->\n[npm]: https://www.npmjs.com\n[node]: https://nodejs.org\n[build-badge]: https://img.shields.io/github/actions/workflow/status/testing-library/eslint-plugin-jest-dom/validate.yml?logo=github&style=flat-square\n[build]: https://github.com/testing-library/eslint-plugin-jest-dom/actions?query=workflow%3Avalidate\n[coverage-badge]: https://img.shields.io/codecov/c/github/testing-library/eslint-plugin-jest-dom.svg?style=flat-square\n[coverage]: https://codecov.io/github/testing-library/eslint-plugin-jest-dom\n[version-badge]: https://img.shields.io/npm/v/eslint-plugin-jest-dom.svg?style=flat-square\n[package]: https://www.npmjs.com/package/eslint-plugin-jest-dom\n[downloads-badge]: https://img.shields.io/npm/dm/eslint-plugin-jest-dom.svg?style=flat-square\n[npmtrends]: http://www.npmtrends.com/eslint-plugin-jest-dom\n[license-badge]: https://img.shields.io/npm/l/eslint-plugin-jest-dom.svg?style=flat-square\n[license]: https://github.com/testing-library/eslint-plugin-jest-dom/blob/main/LICENSE\n[prs-badge]: https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square\n[prs]: http://makeapullrequest.com\n[coc-badge]: https://img.shields.io/badge/code%20of-conduct-ff69b4.svg?style=flat-square\n[coc]: https://github.com/testing-library/eslint-plugin-jest-dom/blob/main/other/CODE_OF_CONDUCT.md\n[emojis]: https://github.com/all-contributors/all-contributors#emoji-key\n[all-contributors]: https://github.com/all-contributors/all-contributors\n[all-contributors-badge]: https://img.shields.io/github/all-contributors/testing-library/eslint-plugin-jest-dom?style=flat-square\n[bugs]: https://github.com/testing-library/eslint-plugin-jest-dom/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Acreated-desc+label%3Abug\n[requests]: https://github.com/testing-library/eslint-plugin-jest-dom/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc+label%3Aenhancement\n[good-first-issue]: https://github.com/testing-library/eslint-plugin-jest-dom/issues?utf8=%E2%9C%93&q=is%3Aissue+is%3Aopen+sort%3Areactions-%2B1-desc+label%3Aenhancement+label%3A%22good+first+issue%22\n<!-- prettier-ignore-end -->\n","publish_time":1574030097623,"_cnpm_publish_time":1574030097623,"dist-tags":{"latest":"5.10.1"}}