Skip to content

I18n.exists method

I18n › exists

Unofficial

Checks whether a translation key exists.

Signature:

exists(key: string | string[], options?: Record<string, unknown> | undefined): boolean

Parameters:

ParameterTypeDescription
keystring | string[]Translation key.
options?Record<string, unknown> | undefinedAdditional options.

Returns: booleanWhether the key exists.