forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiB5fcd955Burak Boduroğlu2 months ago730 commits

getEvents.ts17 lines, 445 bytesHistoryRawDownload
1import { client } from "../client";
2import {
3 normalizePage,
4 pageQuery,
5 type Page,
6 type PageParams,
7 type ScheduleWindowParams,
8} from "../client";
9import type { Event } from "../client";
10
11export async function getEvents(
12 params?: PageParams & ScheduleWindowParams,
13 signal?: AbortSignal
14): Promise<Page<Event>> {
15 const data = await client<unknown>(`/events${pageQuery(params)}`, { signal });
16 return normalizePage<Event>(data);
17}