I want to localize messages in this extension script (Extension:Gadgets/Scripts/SubPages.js). It seems not to be complex code, but I don't know how to internationalize it. Another extension Extension:Gadgets/Scripts/UserRights.js is already done (Tool-link-userrights-readonly at translatewiki). Could anyone help me? Thank you.
Topic on Project:Support desk
These are not parts of the extension, just code snippets which can be copied to other wikis (e.g. to Commons). Neither of them is internationalized, only the user rights gadget is not used as its functionality is present in MediaWiki core (which is, by design, fully internationalized). Internationalizing these gadgets is complicated and there isn’t one common technique. However, Commons’s version is already internationalized so you can ask i18n on the talk page.
I see. I had a misunderstanding of that. I'll ask it there. Thank you very much.