regex - Javascript regular expression - match */ -
i trying write tool whereby enter incorrectly formatted css 1 text area, hit submit , runs few regular expressions , feeds minified , "maxified" css in 2 other textareas. first removes white space (that is, unless within line - white space @ end of line , tabs within line removed). proceeds fall on over next line - reg = new regexp("\*\/", "\g");
. error uncaught syntaxerror: invalid regular expression: /*//: nothing repeat
. can't figure out why is. have idea how resolve this? in advance.
if want */
use reg = /\*\//g;
, if want /*
use reg = /\/\*/g;
.
Comments
Post a Comment