Comment Comment by mitt_romney_12 If you replace the ternary with an if then it's easy to understand for anyone who knows what ... means (which imo every JS developer should know) const count = (amount: number) => { if (amount > 0) { return [...count(amount - 1), amount] } else { return [] }; } parent mitt_romney_12 2 years ago