forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiB4e0a329Burak Boduroğlu2 months ago537 commits

getClassCourses.ts8 lines, 439 bytesHistoryRawDownload
1import { client } from "../client";
2import { normalizePage, pageQuery, type Page, type PageParams } from "../client";
3import type { ClassCourse } from "../client";
4
5export async function getClassCourses(classId: string, params?: PageParams, signal?: AbortSignal): Promise<Page<ClassCourse>> {
6 const data = await client<unknown>(`/classes/${classId}/courses${pageQuery(params)}`, { signal });
7 return normalizePage<ClassCourse>(data);
8}