-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathroute.d.ts
38 lines (32 loc) · 1.17 KB
/
route.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import { History, Path, Location, LocationState, LocationDescriptorObject } from 'history'
export const CALL_HISTORY_METHOD: string;
export interface LocationActionPayload {
method: string;
args?: any[];
}
export interface RouterAction {
type: typeof CALL_HISTORY_METHOD;
payload: LocationActionPayload;
}
export function push(path: Path, state?: LocationState): RouterAction;
export function push(location: LocationDescriptorObject): RouterAction;
export function replace(path: Path, state?: LocationState): RouterAction;
export function replace(location: LocationDescriptorObject): RouterAction;
export function go(n: number): RouterAction
export function goBack(): RouterAction
export function goForward(): RouterAction
export declare const routerRedux: {
push: typeof push,
replace: typeof replace,
go: typeof go,
goBack: typeof goBack,
goForward: typeof goForward,
};
export namespace Route {
export const routerRedux: any;
export const Switch: any;
export const RouteView: any;
export const dynamic: any;
}
export declare function Route(path: string, name?: string, parent?: string): (constructor: Function) => void;
export default Route;