gexiaowei
11/24/2016 - 6:08 PM

正则匹配中英文

Match punctuation in English/Chinese sentenses

var re = /([\[\]\,.?"\(\)+_*\/\\&\$#^@!%~`<>:;\{\}?,。·!¥……()+{}【】、|《》]|(?!\s)'\s+|\s+'(?!\s))/ig;
content.replace(re, '');