> For AI agents: the complete documentation index is available at https://rslint.rs/llms.txt, the full documentation bundle is available at https://rslint.rs/llms-full.txt.

# jestPlugin

`jestPlugin` exposes Rslint's built-in implementation of supported rules from [`eslint-plugin-jest` 29.x](https://github.com/jest-community/eslint-plugin-jest/tree/v29.16.0). Its presets follow the corresponding upstream flat configurations.

```ts
import { defineConfig, jestPlugin } from '@rslint/core';

export default defineConfig([
  {
    ...jestPlugin.configs.recommended,
    files: ['**/*.{test,spec}.{js,mjs,jsx,ts,tsx,mts}'],
  },
]);
```

`jestPlugin.configs.recommended` does not declare `files`; the example scopes it to test and spec files.
All Jest presets include the globals exposed by the Jest runtime.

## Presets

| Preset                           | Description            | View rules                                                                             | Source                                                                                                                               |
| -------------------------------- | ---------------------- | -------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| `jestPlugin.configs.all`         | All Jest rules         | [View rules →](https://rslint.rs/rules/index.md?preset=jestPlugin.configs.all)         | [`eslint-plugin-jest` `configs["flat/all"]`](https://github.com/jest-community/eslint-plugin-jest/tree/v29.16.0#all)                 |
| `jestPlugin.configs.recommended` | Recommended Jest rules | [View rules →](https://rslint.rs/rules/index.md?preset=jestPlugin.configs.recommended) | [`eslint-plugin-jest` `configs["flat/recommended"]`](https://github.com/jest-community/eslint-plugin-jest/tree/v29.16.0#recommended) |
| `jestPlugin.configs.style`       | Jest style rules       | [View rules →](https://rslint.rs/rules/index.md?preset=jestPlugin.configs.style)       | [`eslint-plugin-jest` `configs["flat/style"]`](https://github.com/jest-community/eslint-plugin-jest/tree/v29.16.0#style)             |

See [Rules & Presets](https://rslint.rs/config/rules-and-presets.md) for guidance on choosing and layering presets.
