6 lines
83 B
JavaScript
6 lines
83 B
JavaScript
function foo(...{ length }) {
|
|
return length;
|
|
}
|
|
|
|
expect(foo(1, 2, 3)).toEqual(3);
|