UNPKG

@stackend/api

Version:

JS bindings to api.stackend.com

43 lines 1.22 kB
import { GetPagesResult, Page, SubSite } from './index'; export declare const RECEIVE_PAGES = "RECEIVE_PAGES"; export declare const CLEAR_PAGE = "CLEAR_PAGE"; export declare const CLEAR_PAGES = "CLEAR_PAGES"; export declare const RECEIVE_SUB_SITES = "RECEIVE_SUB_SITES"; export declare const CLEAR_SUB_SITES = "CLEAR_SUB_SITES"; export interface PagesState { byId: { [id: string]: PageAndLoadedState | null; }; idByPermalink: { [permalink: string]: number | null; }; subSiteById: { [id: string]: SubSite; }; subSiteIdByPermalink: { [permalink: string]: number | null; }; } export interface PageAndLoadedState extends Page { loaded: number; } export declare type PageActions = { type: typeof RECEIVE_PAGES; json: GetPagesResult; pageIds?: Array<number>; permalinks?: Array<string>; } | { type: typeof CLEAR_PAGE; id: number; } | { type: typeof CLEAR_PAGES; } | { type: typeof RECEIVE_SUB_SITES; subSites: { [id: string]: SubSite; }; } | { type: typeof CLEAR_SUB_SITES; }; export default function (state: PagesState | undefined, action: PageActions): PagesState; //# sourceMappingURL=pageReducer.d.ts.map