Skip to content

Instantly share code, notes, and snippets.

@opr
Created May 10, 2020 09:07
Show Gist options
  • Save opr/155a77a917a23e6bae13ea8f58577942 to your computer and use it in GitHub Desktop.
Save opr/155a77a917a23e6bae13ea8f58577942 to your computer and use it in GitHub Desktop.
Regex for matching functions defined using the function keyword
Find: function (\w*)\s?(\(.*?\))\s?\{
Replace with: const $1 = $2 => {
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment