import { Hookable } from '@shuvi/hooks'; import { IApplication, IAppRouteConfig, IAppRenderFn, IRerenderConfig } from '../../types'; export declare type IContext = { [x: string]: any; }; export interface IApplicationOptions { AppComponent: any; routes: IAppRouteConfig[]; context: Context; render: IAppRenderFn; } export declare class Application extends Hookable implements IApplication { AppComponent: any; routes: IAppRouteConfig[]; private _renderFn; private _context; constructor(options: IApplicationOptions); run(): Promise; rerender({ AppComponent, routes }?: IRerenderConfig): Promise; dispose(): Promise; getContext(): IContext; private _init; private _createApplicationContext; private _getAppComponent; private _render; }