(fixable) The --fix
option on the command line automatically fixes problems reported by this rule.
Examples of incorrect code for this rule:
/*eslint no-useless-rest-spread: "error"*/
let list = [a, ...[b, c], d]
foo(...[a, b, c])
let [a, b, ...[c, d]] = list;
function foo(a, b, ...[c, d]) {
}
Examples of correct code for this rule:
/*eslint no-useless-rest-spread: "error"*/
let list = [a, b, c, d]
foo(a, b, c)
let [a, b, c, d] = list;
function foo(a, b, c, d) {
}