nuxt 不支持 replaceAll 方法

在使用 nuxt 的 ssr 时使用 replaceAll 方法时报错 ‘replaceAll’ does not exist
是因为 nuxt 不支持 String 的 replaceAll 方法
可以使用 replace(new RegExp(a, "gm"), b) 来替代 replaceAll(a, b) 的写法