What is the rest operator in JS?

In JavaScript functions, rest gets used as a prefix of the function’s last parameter. The rest operator ( … ) instructs the computer to add whatever otherInfo (arguments) supplied by the user into an array . Then, assign that array to the otherInfo parameter.15 Eyl 2021

Sizin İçin Seçtik  What does 3 dots in JavaScript mean?

Leave a Reply

Your email address will not be published. Required fields are marked *