Directus / @directus/sdk / types / QueryFieldsRelational
Type Alias: QueryFieldsRelational<Schema, Item> ​
QueryFieldsRelational<
Schema
,Item
>:IfNever
<RelationalFields
<Schema
,Item
>,never
,{ [Key in RelationalFields<Schema, Item>]?: Extract<Item[Key], ItemType<Schema>> extends infer RelatedCollection ? RelatedCollection extends any[] ? HasManyToAnyRelation<RelatedCollection> extends never ? QueryFields<Schema, RelatedCollection> : ManyToAnyFields<Schema, RelatedCollection> : QueryFields<Schema, RelatedCollection> : never }
>
Object of nested relational fields in a given Item with it's own fields available for selection
Type Parameters ​
• Schema
• Item