Skip to content

Instantly share code, notes, and snippets.

@tim-smart
Created October 1, 2010 00:12
Show Gist options
  • Save tim-smart/605530 to your computer and use it in GitHub Desktop.
Save tim-smart/605530 to your computer and use it in GitHub Desktop.
--langdef=js
--langmap=js:.js
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*\{/\1/,object/
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*function[A-Za-z0-9_$ \t]*\(/\1/,function/
--regex-js=/function[ \t]+([A-Za-z0-9_$]+)[ \t]*([^)])/\1/,function/
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*\[/\1/,array/
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*[^"]'[^']*/\1/,string/
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*[^']"[^"]*/\1/,string/
--regex-js=/([A-Za-z0-9_$]+)[ \t]*[:=][ \t]*[0-9]+/\1/,number/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment