\s
exampleyou can try to run the following code to find non-whitespace character −
<html> <head> <title>javascript regular expression</title> </head> <body> <script> var mystr = "100% responsive!"; var reg = /\s/g; var match = mystr.match(reg); document.write(match); </script> </body></html>
以上就是使用javascript正则表达式查找非空格字符的详细内容。