Skip to main content

TranslatorOptions

Index

Properties

optionalautoDetect

autoDetect?: boolean

Automatically detect the locale from the environment. Defaults to true.

optionaldebug

debug?: boolean

Enable debugging by logging info to the console.

optionalfallbackLocale

fallbackLocale?: string | string[]

Fallback locale(s) to use when the detected locale isn't translated. Defaults to en.

optionallocale

locale?: string

Locale to explicitly use.

optionallookupType

lookupType?: all | currentOnly | languageOnly

Order in which to load and lookup locale translations.

optionalresourceFormat

resourceFormat?: Format

File format resource bundles are written in. Defaults to yaml.