Last active
May 2, 2017 19:06
-
-
Save kosperera/5c80840babc61ccc3ad7626415efb028 to your computer and use it in GitHub Desktop.
Reverse a string value in JavaScript.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
String.prototype.reverse = () => { | |
return this.split('').reverse().join(''); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Usage