function sortFingerprint
Since 0.2.0
sortFingerprint(orderBy: Readonly<Record<string, OrderDirection>>): string

Build the stable sort fingerprint embedded in every minted cursor.

The fingerprint must be stable across all calls with the same sort — a cursor minted under one sort and presented under another carries a different fingerprint and is refused by name rather than served a silently wrong page.

Parameters

orderBy: Readonly<Record<string, OrderDirection>>

The resolved sort specification

Return Type

string

A stable fingerprint string ('field:direction' pairs joined by commas, in orderBy declaration order)

Usage

import { sortFingerprint } from "common/src/index.ts";