Files
gamestream-webtransport-proxy/frontend/src/routes/apps.ts
T

21 lines
400 B
TypeScript

export interface App {
title: string;
id: number;
hdr_supported: boolean;
active: boolean;
}
export interface AppsResponse {
apps: Record<string, App[]>;
}
export async function fetchApps() {
console.log('Getting apps');
const response = await fetch('/api/apps');
console.log(response);
const data = (await response.json()) as AppsResponse;
console.log(data);
return data;
}