forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

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

getAcademicYears.ts9 lines, 454 bytesHistoryRawDownload
1import { client } from "../client";
2import { normalizePage, pageQuery, type Page, type PageParams } from "../client";
3import type { AcademicYear } from "../client";
4
5/** Newest first. Requires teacher+. */
6export async function getAcademicYears(params?: PageParams, signal?: AbortSignal): Promise<Page<AcademicYear>> {
7 const data = await client<unknown>(`/academic-years${pageQuery(params)}`, { signal });
8 return normalizePage<AcademicYear>(data);
9}