Skip to content

Commit 0b67275

Browse files
committed
fix(exclude-list): add another way to validate exclude list
1 parent 9040254 commit 0b67275

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@eduzz/eslint-config",
33
"private": false,
4-
"version": "2.5.4",
4+
"version": "2.5.5",
55
"keywords": [
66
"eduzz",
77
"eslint"

rules/requiredId.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,9 @@ module.exports = {
8989

9090
if (
9191
node.name.type === 'JSXMemberExpression' &&
92-
excludeNestedComponentsNameList.includes([node.name.object.name, node.name.property.name])
92+
excludeNestedComponentsNameList.some(
93+
([parent, children]) => parent === node.name.object.name && children === node.name.property.name
94+
)
9395
) {
9496
return;
9597
}

0 commit comments

Comments
 (0)