244 B
244 B
Reverse a string
Use array destructuring and Array.reverse() to reverse the order of the characters in the string.
Combine characters to get a string using join('').
const reverseString = str => [...str].reverse().join('');