Skip to main content

ModalitiesArrayToUnion

还没翻译译自英文(tanstack.com)本页 6 段都还没译

type ModalitiesArrayToUnion<T> = T[number];

Defined in: packages/ai/src/types.ts:361

Helper type to convert a readonly array of modalities to a union type. e.g., readonly ['text', 'image'] -> 'text' | 'image'

Type Parameters

T

T extends ReadonlyArray<Modality>