1function func1() {
2 const reverse = func2(...arguments); // "rest operator" passes arguments
3 return reverse.join("");
4}
5
6function func2() {
7 return Array.from(arguments).reverse();
8}
9
10func1("a", "b", "c"); // "cba"
1Like many of the others, I often prefer passing an options object to
2a function instead of passing a long list of parameters, but it
3really depends on the exact context.
4
5I use code readability as the litmus test.