Closed
Description
I'd like to use the prefer-destructuring
rule from ESLint, however, when I try to use array destructuring with an Express request object, I get the following TypeScript Error:
Type 'ParamsDictionary' must have a '[Symbol.iterator]()' method that returns an iterator.ts(2488)
.
That seems reasonable, but then the base ESLint prefer-destructuring
rule gives me a warning, even though TypeScript claims I'm not allowed to use array destructuring here.
I think having a type-aware version of this rule would be beneficial.