Skip to content

Instantly share code, notes, and snippets.

@adenhertog
Created January 4, 2017 12:13
Show Gist options
  • Save adenhertog/a7a32503c54e234ad54fc87c7e9f1075 to your computer and use it in GitHub Desktop.
Save adenhertog/a7a32503c54e234ad54fc87c7e9f1075 to your computer and use it in GitHub Desktop.
javascript match regex
"gets the last word in the string".match(/\w+$/)[0]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment