Skip to content
On this page

stratadb / OrderingOperators

Type Alias: OrderingOperators<T>

ts
type OrderingOperators<T> = T extends number | Date ? object : never;

Defined in: src/query-types.ts:62

Ordering comparison operators (greater than, less than).

Type Parameters

T

T

The field type (must be number or Date)

Remarks

These operators are only available for types that support natural ordering: numbers and dates. This prevents nonsensical comparisons like checking if one string is "greater than" another string.

Released under the MIT License.