Skip to content
module@warp-drive/core/types/cache/relationship

Interface CollectionRelationship<T> ​

Defined in: warp-drive-packages/core/src/types/cache/relationship.ts:50

The stable-cache-key form of a to-many relationship.

Unlike CollectionResourceRelationship, each entry in data is always in the stable ResourceKey form rather than a raw resource identifier.

Example ​

ts
const relationship: CollectionRelationship = { data: [resourceKey] };

Type Parameters ​

T ​

T = ResourceKey

Properties ​

data? ​

ts
optional data?: T[];

Defined in: warp-drive-packages/core/src/types/cache/relationship.ts:54

the related resources


ts
optional links?: PaginationLinks;

Defined in: warp-drive-packages/core/src/types/cache/relationship.ts:62

links related to the relationship, including pagination links


meta? ​

ts
optional meta?: ObjectValue;

Defined in: warp-drive-packages/core/src/types/cache/relationship.ts:58

meta information about the relationship

Released under the MIT License.