Return to Snippet

Revision: 70220
at December 11, 2015 06:47 by brandonjp


Initial Code
/^(\s*)?[^\/]{0,2}((\$log|console)\.(warn|log|info))(.*)$/gmi

in Sublime Text: ^(\s*)?[^\/]{0,2}(\$log\.(warn|log|info))(.*)$ 

test/play here: http://refiddle.com/refiddles/js-and-angular-non-comment-logs

Initial URL
http://refiddle.com/refiddles/js-and-angular-non-comment-logs

Initial Description
Regular Expression to find native Javascript console and AngularJS $log log warn or info that are NOT comments / commented out

Initial Title
RegExp to find JS & Angular non-comment logs

Initial Tags
regex, javascript, js, regexp, log

Initial Language
Regular Expression