Skip to content

Commit

Permalink
ESLint: Restrict removed Lodash functions (#41651)
Browse files Browse the repository at this point in the history
* ESLint: Restrict removed Lodash fns

* Combine rule extensions
  • Loading branch information
tyxla authored Jun 10, 2022
1 parent 5370bd7 commit 2fa50a6
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,20 @@ module.exports = {
},
{
name: 'lodash',
importNames: [ 'memoize' ],
message: 'Please use `memize` instead.',
importNames: [
'differenceWith',
'findIndex',
'isUndefined',
'memoize',
'negate',
'random',
'reverse',
'stubFalse',
'stubTrue',
'sum',
],
message:
'This Lodash method is not recommended. Please use native functionality instead. If using `memoize`, please use `memize` instead.',
},
{
name: 'reakit',
Expand Down

0 comments on commit 2fa50a6

Please sign in to comment.