Type alias Vertex<GraphSchema, NodeName, Node>

Vertex<GraphSchema, NodeName, Node>: _Vertex<GraphSchema, NodeName, Node> & { [ K in keyof Node["rels"] as Node["rels"][K] extends RelationShape<true> ? K : never]: (() => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>[]>) & (Node["rels"][K] extends RelationShape<true, infer To, infer Labels, infer Props> ? Empty extends Props ? ((target: Vertex<GraphSchema, Node["rels"][K] extends RelationShape<true, infer To> ? To : never>) => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>>) : ((target: Vertex<GraphSchema, Node["rels"][K] extends RelationShape<true, infer To> ? To : never>, props: Node["rels"][K] extends RelationShape<true, infer To, infer Labels, infer Props> ? { [ P in keyof Props]: Props[P] extends z.ZodType ? z.infer<Props[P]> : never } : never) => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>>) : never) } & { [ K in keyof Node["rels"] as Node["rels"][K] extends RelationShape<false> ? K : never]: (() => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>>) & (Node["rels"][K] extends RelationShape<false, infer To, infer Labels, infer Props> ? Empty extends Props ? ((target: Vertex<GraphSchema, Node["rels"][K] extends RelationShape<false, infer To> ? To : never>) => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>>) : ((target: Vertex<GraphSchema, Node["rels"][K] extends RelationShape<false, infer To> ? To : never>, props: Node["rels"][K] extends RelationShape<false, infer To, infer Labels, infer Props> ? { [ P in keyof Props]: Props[P] extends z.ZodType ? z.infer<Props[P]> : never } : never) => Promise<Relation<GraphSchema, NodeName, K extends keyof GraphSchema[NodeName] ? K : never>>) : never) }

Type Parameters

  • GraphSchema extends FullGraph

  • NodeName extends keyof GraphSchema

  • Node extends GraphSchema[NodeName] = GraphSchema[NodeName]

Generated using TypeDoc