Js替换字符串中的所有空格

name.replace(/s+/g,"");

原文地址:https://www.cnblogs.com/413xiaol/p/6810214.html