data.replaceAll is not a function
HouDiZhong opened this issue · 1 comments
HouDiZhong commented
const replaceAttrMatcher = new RegExp("{=$}", "gi")
data = data.replaceAll(replaceAttrMatcher)
Regular is already a global mode,No need to use replaceAll,And replaceAll support is not good
donnikitos commented
Seems like that happens with NodeJS before version 15, due to not implemented .replaceAll()
function.
Will use .replace()
for broader support.