Skip to content

Latest commit

 

History

History
17 lines (9 loc) · 1.21 KB

i18n.md

File metadata and controls

17 lines (9 loc) · 1.21 KB

This project outputs HTML in which user interface elements are localized to suite the user's preference.

Language-specific content is organized in messages that can be retrieved using their keys.

To avoid redundant record keeping with messages already existing inside mediawiki/wikibase, this project explicitly only deals with the keys, importing the message values from there.

Available messages

Not all messages existing in mediawiki/wikibase are automatically known to this project. To be able to use a message, make sure to add its key to MessageKey.

In terms of integration with wikibase this leads to a special case: Wikibase reads from this repository's resource.json in order to load the required message keys from Wikibase/MediaWiki's i18n service.

Messages in components

Messages can be used inside component templates by using the Messages mixin.

Components can use messages in their templates by using the message method, and the MESSAGE_KEYS property provided by the mixin, e.g. message( MESSAGE_KEYS.ALIAS_SEPARATOR ).