UNPKG

ggejs

Version:

A powerful JavaScript library for interacting with the server of Goodgame Empire: Four Kingdoms

9 lines (8 loc) 318 B
const TextValide = { /** @param {string} msgText */ parseChatJSONMessage(msgText) { if (!msgText) return ""; return msgText.replace(/&percnt;/g, "%").replace(/&quot;/g, "\"").replace(/&#145;/g, "\'").replace(/<br \/>/g, "\n").replace(/&lt;/g, "<"); } } module.exports = TextValide;