Skip to content

API reference / @localizer/translate / FlatStructure

Type Alias: FlatStructure<K, V>
experimental

FlatStructure<K, V> = { [key in K]: { [locale in LocaleCode]?: V } }

Defined in: types/dictionary.ts:72

Represents a mapping where each key of type K corresponds to an object. This object maps locale codes (LocaleCode) to values of type V. The value for a specific locale can be undefined if no value is provided for that locale.

Type Parameters

Type ParameterDescription
K extends stringA string type representing the keys of the structure.
VThe type of the values associated with each locale.