Inspectopedia
 
2024.3

Redundant argument-based 'let' call

Info
New
Last modified: 03 December 2024

Reports a redundant argument-based let call.

let is redundant when the lambda parameter is only used as a qualifier in a call expression.

If you need to give a name to the qualifying expression, declare a local variable.

Example:

The quick-fix removes the extra let() call:

Alternative: