remotes.ts
1 import { API_URL } from "../constants" 2 3 export interface RepositoryRemote { 4 id: string 5 alias: string 6 delegate: boolean 7 // note: probably a Record<string, string> 8 heads: { 9 main: string 10 } 11 } 12 13 export const getRepositoryRemotes = async (rid: string): Promise<Array<RepositoryRemote>> => 14 fetch(`${API_URL}/repos/${rid}/remotes`) 15 .then(res => res.json())