Lang functions
Use these functions to adapt your site to meet language and regional requirements.
Use these functions to adapt your site to meet language and regional requirements.
lang.FormatAccounting PRECISION CURRENCY NUMBER ⟼ stringReturns a currency representation of a number for the given currency and precision for the current language and region in accounting notation. 詳しく見る »
lang.FormatCurrency PRECISION CURRENCY NUMBER ⟼ stringReturns a currency representation of a number for the given currency and precision for the current language and region. 詳しく見る »
lang.FormatNumber PRECISION NUMBER ⟼ stringReturns a numeric representation of a number with the given precision for the current language and region. 詳しく見る »
lang.FormatNumberCustom PRECISION NUMBER [OPTIONS...] ⟼ stringReturns a numeric representation of a number with the given precision using negative, decimal, and grouping options. 詳しく見る »
lang.FormatPercent PRECISION NUMBER ⟼ stringReturns a percentage representation of a number with the given precision for the current language and region. 詳しく見る »
lang.Merge FROM TO ⟼ anyMerge missing translations from other languages. 詳しく見る »
lang.Translate KEY [CONTEXT] ⟼ stringTranslates a string using the translation tables in the i18n directory. 詳しく見る »