i18n-ally
i18n-ally copied to clipboard
[Framework Request] sapphire-i18next support
What framework do you want to have? Please provide links of its i18n solution/package. sapphire-i18next It is a plugin for Sapphire Framework - Discord bot framework built on top of discord.js for advanced and amazing bots.
Please provide some overall screenshots about how the i18n usage would be like
resolveKey
method:
sendLocalized
method:
replyLocalized
method:
editLocalized
method:
Please provide a minimal starter project
Additional context Since the plugin uses i18next, the only difference are those methods. So I think we can just use a new Regex. This is the Regex I figured out 😂 idk whether it can be shortened or not:
/[^\w\d](?:(?:resolveKey)|(?:(?:send)|(?:reply)|(?:edit))Localized)\(\s*?.*?\s*?,\s*?(?:{?\s*?(?:.*?,)?\s*?(?:keys:)?\s*?\[?['"`]({key})['"`]\]?\s*?(?:,[\s\S]*?)?}?)\)/