forge
Explore
Log in

Don't you dare go Hollow

hezarfen_frontend

Clone
★ 0

0 watching0 forksTypeScript5.5 MiBdcf123aBurak Boduroğlu2 months ago674 commits

getMyCourses.ts9 lines, 452 bytesHistoryRawDownload
1import { client } from "../client";
2import { normalizePage, type Page } from "../client";
3import type { Course } from "../client";
4import { courseListQuery, type CourseListParams } from "../courses/getCourses";
5
6export async function getMyCourses(params?: CourseListParams, signal?: AbortSignal): Promise<Page<Course>> {
7 const data = await client<unknown>(`/courses/me${courseListQuery(params)}`, { signal });
8 return normalizePage<Course>(data);
9}