const str = "<p>和还是科室刚开始的个啥的积分开幕式的</p><img src=""></img><span></span>"
cont res = str.replace(/<img(.*?)>+(.*?)+(<\/img>)/g, '');
console.log(res) // '<p>和还是科室刚开始的个啥的积分开幕式的</p><span></span>'
标签:为空,img,res,js,开幕式,科室,str,积分,log
来源: https://www.cnblogs.com/zhang-jiao/p/14346141.html