mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-01 16:00:29 +02:00
chore: tighten ESLint config (#6931)
* chore: tighten ESLint config * more refactor * refactor push * fix
This commit is contained in:
parent
f70ddf7e69
commit
cc0bceab9c
54 changed files with 177 additions and 193 deletions
|
@ -23,7 +23,7 @@ function testStylelintRule(config, tests) {
|
|||
const checkTestCaseContent = (testCase) =>
|
||||
testCase.description || testCase.code || 'no description';
|
||||
|
||||
if (tests.accept && tests.accept.length) {
|
||||
if (tests.accept?.length) {
|
||||
describe('accept cases', () => {
|
||||
tests.accept.forEach((testCase) => {
|
||||
it(`${checkTestCaseContent(testCase)}`, async () => {
|
||||
|
@ -46,7 +46,7 @@ function testStylelintRule(config, tests) {
|
|||
});
|
||||
}
|
||||
|
||||
if (tests.reject && tests.reject.length) {
|
||||
if (tests.reject?.length) {
|
||||
describe('reject cases', () => {
|
||||
tests.reject.forEach((testCase) => {
|
||||
it(`${checkTestCaseContent(testCase)}`, async () => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue