@perfective/eslint-config
Version:
ESLint shareable rules configuration
23 lines • 766 B
JavaScript
import eslintPluginJestDom from 'eslint-plugin-jest-dom';
import { jestFiles } from "../../linter/glob.js";
export function jestDomConfig(files = jestFiles) {
return {
files,
plugins: {
'jest-dom': eslintPluginJestDom
},
rules: {
'jest-dom/prefer-checked': 'warn',
'jest-dom/prefer-empty': 'warn',
'jest-dom/prefer-enabled-disabled': 'warn',
'jest-dom/prefer-focus': 'warn',
'jest-dom/prefer-in-document': 'off',
'jest-dom/prefer-required': 'warn',
'jest-dom/prefer-to-have-attribute': 'warn',
'jest-dom/prefer-to-have-class': 'warn',
'jest-dom/prefer-to-have-style': 'warn',
'jest-dom/prefer-to-have-text-content': 'warn',
'jest-dom/prefer-to-have-value': 'warn'
}
};
}