对部分后端返回的富文本进行替换、修改:
//假设获取到的富文本为:
let str = res.data.content
单个替换:
let html=str.replace(/替换目标",替换内容)
//例如(图片):let html=str.replace(/<img style=",'style="width:100%;display:block;')
全局替换:
let html=str.replace(/替换目标/g",替换内容)
//例如(文字):let html=str.replace(/apply/g,'apply1')