Skip to content

QueryContext

What a search clause receives besides the words of the search: the current time, the person who searches, and a function that reads days.

readonly now: number;

The current time, in milliseconds.


readonly viewer: string | null | undefined;

The id of the person who searches, or null or undefined when there is none.

parseDay(text): string | null;

Reads a day that is written as a date or in words.

Parameter Type Description
text string the text, for example 2026-11-24 or friday

string | null

the day, or null when the text is not a day