Diagnostics/Scribunto/LanguageLibrary

From XOWA: the free, open-source, offline wiki application

Language Library

name code actl rslt
pass getContLangCode (by getContentLanguage) {{#invoke:Diagnostics/LanguageLibrary|getContLangCode}} en


pass isKnownLanguageTag; true {{#invoke:Diagnostics/LanguageLibrary|isKnownLanguageTag|en}} true


pass isKnownLanguageTag; false {{#invoke:Diagnostics/LanguageLibrary|isKnownLanguageTag|xyz}} false


pass isValidCode; true {{#invoke:Diagnostics/LanguageLibrary|isValidCode|en}} true


pass isValidCode; false {{#invoke:Diagnostics/LanguageLibrary|isValidCode|a[b}} false


pass isValidBuiltInCode; true {{#invoke:Diagnostics/LanguageLibrary|isValidBuiltInCode|en}} true


pass isValidBuiltInCode; false {{#invoke:Diagnostics/LanguageLibrary|isValidBuiltInCode|a#b}} false


pass fetchLanguageName; code only {{#invoke:Diagnostics/LanguageLibrary|fetchLanguageName|en|en}} English


pass fetchLanguageNames_get {{#invoke:Diagnostics/LanguageLibrary|fetchLanguageNames_get|fr}} fran├žais


pass new {{#invoke:Diagnostics/LanguageLibrary|new_lang_code|fr}} fr


pass formatNum; en {{#invoke:Diagnostics/LanguageLibrary|formatNum|1234}} 1,234


pass parseFormatteNum; en {{#invoke:Diagnostics/LanguageLibrary|parseFormattedNum|1,234}} 1,234


pass formatDate via pcall; y; {{#invoke:Diagnostics/LanguageLibrary|formatDate_valid|Y-m-d|2014-03-25}} y


pass formatDate via pcall; n; {{#invoke:Diagnostics/LanguageLibrary|formatDate_valid|Y-m-d|fail}} n


pass convertGrammar {{#invoke:Diagnostics/LanguageLibrary|convertGrammar|fi|talo|elative}} talosta


pass isRTL; en {{#invoke:Diagnostics/LanguageLibrary|isRTL|en}} false


pass isRTL; ar {{#invoke:Diagnostics/LanguageLibrary|isRTL|ar}} true


pass format_durations_hms {{#invoke:Diagnostics/LanguageLibrary|format_durations_hms|123}} 2 minutes and 3 seconds


pass get_duration_intervals_hms {{#invoke:Diagnostics/LanguageLibrary|get_duration_intervals_hms|123}} ,2,3


Namespaces

XOWA

Getting started

Android

Help

Blog

Donate