-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add optional
jestDomConfig()
for eslint-plugin-jest-dom
- Loading branch information
1 parent
6754650
commit 528407a
Showing
4 changed files
with
16 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
const perfectiveEslintConfig = require('./dist'); | ||
|
||
const { cypressConfig } = require('./dist/cypress'); | ||
const { jestDomConfig } = require('./dist/jest-dom'); | ||
const { rxjsConfig } = require('./dist/rxjs'); | ||
const { testingLibraryConfig } = require('./dist/testing-library'); | ||
|
||
module.exports = [ | ||
...perfectiveEslintConfig.default, | ||
cypressConfig(), | ||
jestDomConfig(), | ||
rxjsConfig(), | ||
testingLibraryConfig(), | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import { jestDomConfig as jestDomPluginConfig } from './rules/jest-dom'; | ||
|
||
export function jestDomConfig(files: string[] = ['**/*.@(spec|test).[jt]s?(x)']): Record<string, unknown> { | ||
return { | ||
files, | ||
plugins: jestDomPluginConfig.plugins, | ||
rules: jestDomPluginConfig.rules, | ||
}; | ||
} |