JS问题,去掉字符串的前后空格String.prototype.trim=function() {return this.replace((^s*)|(s*$)g,'')}var str=" test "alert2023-02-21JavaScript190