js常用自定义公共函数汇总 复制代码 代码如下: String prototype trim = function(){ return this replace( (^ s*)|( s*$) g, ""); JavaScript 2022-04-26 180 点赞 2 评论 272 浏览