File tree 2 files changed +26
-0
lines changed
2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ export {
10
10
RouterOptions ,
11
11
RouteConfig ,
12
12
RouteRecord ,
13
+ RouteRecordPublic ,
13
14
Location ,
14
15
Route ,
15
16
NavigationGuard ,
Original file line number Diff line number Diff line change @@ -47,6 +47,11 @@ export declare class VueRouter {
47
47
onReady ( cb : Function , errorCb ?: ErrorHandler ) : void
48
48
onError ( cb : ErrorHandler ) : void
49
49
addRoutes ( routes : RouteConfig [ ] ) : void
50
+
51
+ addRoute ( parent : string , route : RouteConfig ) : void
52
+ addRoute ( route : RouteConfig ) : void
53
+ getRoutes ( ) : RouteRecordPublic [ ]
54
+
50
55
resolve (
51
56
to : RawLocation ,
52
57
current ?: Route ,
@@ -158,6 +163,26 @@ export interface RouteRecord {
158
163
| Dictionary < boolean | Object | RoutePropsFunction >
159
164
}
160
165
166
+ export interface RouteRecordPublic {
167
+ path : string
168
+ components : Dictionary < Component >
169
+ instances : Dictionary < Vue >
170
+ name ?: string
171
+ redirect ?: RedirectOption
172
+ meta : any
173
+ beforeEnter ?: (
174
+ route : Route ,
175
+ redirect : ( location : RawLocation ) => void ,
176
+ next : ( ) => void
177
+ ) => any
178
+ props :
179
+ | boolean
180
+ | Object
181
+ | RoutePropsFunction
182
+ | Dictionary < boolean | Object | RoutePropsFunction >
183
+ }
184
+
185
+
161
186
export interface Location {
162
187
name ?: string
163
188
path ?: string
You can’t perform that action at this time.
0 commit comments