Closed getify closed 5 years ago
Some people like to define arrows like this:
x => 1; x => {}; x => void 0;
Those forms are all generally to avoid the () => ... But since this can be confusing to a reader to see a parameter listed that isn't used, this rule would forbid that.
() => ..
It would also catch straight-up mistakes like:
(x,y,z) => x + y; // z is unused here
This is similar to the built-in "no-unused-vars" rule, but is much narrower in focus: only for arrow functions.
Some people like to define arrows like this:
Those forms are all generally to avoid the
() => ..
. But since this can be confusing to a reader to see a parameter listed that isn't used, this rule would forbid that.It would also catch straight-up mistakes like:
This is similar to the built-in "no-unused-vars" rule, but is much narrower in focus: only for arrow functions.