Recursion in JavaScript with ES6, destructuring and rest/spreadby@hugo__df