Remote / foldkit-remote-server

LiveQuery

interface · packages/remote-server/src/index.ts:648

interface LiveQuery<R = never> {
  readonly identity: string
  readonly select: RelationRequirement
  readonly edges: Effect.Effect<QueryPage['edges'], RemoteServerError, R>
}

A list a subscriber reads live (Data.query(…, { live: true })), admitted and resolved by handlers: what a live source diffs to tell a row that joins, changes or leaves it.

In the guides

Members

LiveQuery.identity

property · packages/remote-server/src/index.ts:650

readonly identity: string

The connection, as the client keys it: the query's name and input.

LiveQuery.select

property · packages/remote-server/src/index.ts:652

readonly select: RelationRequirement

What its read selects of each row, of the entity it lists.

LiveQuery.edges

property · packages/remote-server/src/index.ts:654

readonly edges: Effect.Effect<QueryPage['edges'], RemoteServerError, R>

Its window as the subscriber reads it now: the registered query, run as them.