Skip to content

Commit

Permalink
no-array-callback-reference: Check .findLast and .findLastIndex (
Browse files Browse the repository at this point in the history
  • Loading branch information
fisker committed Sep 17, 2022
1 parent 39f0679 commit 37a5cda
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
16 changes: 16 additions & 0 deletions rules/no-array-callback-reference.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,14 @@ const iteratorMethods = [
],
},
],
[
'findLast',
{
ignore: [
'Boolean',
],
},
],
[
'findIndex',
{
Expand All @@ -47,6 +55,14 @@ const iteratorMethods = [
],
},
],
[
'findLastIndex',
{
ignore: [
'Boolean',
],
},
],
[
'flatMap',
],
Expand Down
2 changes: 2 additions & 0 deletions test/no-array-callback-reference.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ const simpleMethods = [
'filter',
'find',
'findIndex',
'findLast',
'findLastIndex',
'flatMap',
'forEach',
'map',
Expand Down

0 comments on commit 37a5cda

Please sign in to comment.