import { API } from '../core/api' ; import { FeedItemList } from '../models' ; export type FeedModes = 'chrono' | 'annotated' | 'stacks' ; extends API export default class Feed extends API { param thread param offset param limit param mode async list ( thread ? , offset ? , limit ? , mode ? ) { const response = await this . sendGet ( 'feed' , undefined , { thread : thread || '' , offset : offset || '' , limit : limit || 5 , mode : mode || 'chrono' } ) ; return response . json ( ) as Promise < FeedItemList > ; } }