i18n Mustache for MediaWiki - free and open source
If you are building a multilingual MediaWiki site and using Mustache for templating - the extension is for you. The Mustache_i18n extension adds built-in i18n (internationalization) support to Mustache, letting you embed translation keys directly in your Mustache templates with ease
The extension adds two helper functions to Mustache templates:
• {{ _ "message-key" }} — returns a plain translated string
• {{ __ "message-key" }} — returns a parsed translated string
The extension is licensed under MIT, so you can freely adopt, modify, or distribute it.
It's simple to install, just drop it in your extensions/ folder and call:
wfLoadExtension('Mustache_i18n') in your LocalSettings.php
Limitations:
- It patches MediaWiki’s template handling by overriding the loading class list via $wgAutoloadLocalClasses — which can lead to compatibility issues after major MediaWiki upgrades if not maintained
- Because templates may be cached, localized output can sometimes mis-align (this is more of a templating system issue than this extension)
- Parametrized messages are not supported (i.e. you can’t pass in variables to your translations)
The extension documentation can be found on the official MediaWiki page https://www.mediawiki.org/wiki/Extension:Mustache_i18n
zip
mediawiki-extension-Mustache_i18n-master.zip6.70 Kb
mediawiki
extension
free
open-source
Creator has disabled comments for this post.