You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
37 lines
830 B
37 lines
830 B
4 years ago
|
export declare class Router {
|
||
|
constructor(op: {[key: string]: string});
|
||
|
|
||
|
route(route: string, callback: Function): this;
|
||
|
route(route: string, name: string, callback?: Function): this;
|
||
|
|
||
|
execute(callback?: Function, args?: any[]): void;
|
||
|
|
||
|
navigate(fragment: string, options?: {[key: string]: any} | boolean): this;
|
||
|
}
|
||
|
|
||
|
export declare class History {
|
||
|
atRoot(): boolean;
|
||
|
|
||
|
getSearch(): string;
|
||
|
|
||
|
getHash(window?: Window): string;
|
||
|
|
||
|
getPath(): string;
|
||
|
|
||
|
getFragment(fragment?: string): string;
|
||
|
|
||
|
start(op: {[key: string]: any}): void;
|
||
|
|
||
|
stop(): void;
|
||
|
|
||
|
route(route: string, callback: Function): void;
|
||
|
|
||
|
unRoute(route: string): void;
|
||
|
|
||
|
checkUrl(e?: Event): void;
|
||
|
|
||
|
loadUrl(fragment: string): boolean;
|
||
|
|
||
|
navigate(fragment: string, options?: {[key: string]: any} | boolean): void;
|
||
|
}
|