Skip to content

I18n.getResource method

I18n › getResource

Unofficial

Gets a single resource value.

Signature:

getResource(lng: string, ns: string, key: string, options?: GetResourceOptions | undefined): unknown

Parameters:

ParameterTypeDescription
lngstringLanguage code.
nsstringNamespace.
keystringResource key.
options?GetResourceOptions | undefinedAdditional options including keySeparator.

Returns: unknownThe resource value.