Skip to content

API reference / @localizer/transform / usePrimaryLocale

Function: usePrimaryLocale()
preview

usePrimaryLocale<T>(value): Localizable<T>

Defined in: fn/generic/usePrimaryLocale.ts:29

Transforms a Localizable value to use the primary locale.

Type Parameters

Type ParameterDescription
TType of the value in the Localizable object.

Parameters

ParameterTypeDescription
valueLocalizable<T>The Localizable object to transform.

Returns

Localizable<T>

A new Localizable object using the primary locale.