File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Filter options
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Original file line number Diff line number Diff line change 8
8
Introducing an API that allows adding and removing route records while the router is working
9
9
10
10
- ` router.addRoute(route: RouteRecord) ` Add a new route
11
- - ` router.removeRoute(name: string | Symbol ) ` Remove an existing route
12
- - ` router.hasRoute(name: string | Symbol ): boolean ` Check if a route exists
11
+ - ` router.removeRoute(name: string | symbol ) ` Remove an existing route
12
+ - ` router.hasRoute(name: string | symbol ): boolean ` Check if a route exists
13
13
- ` router.getRoutes(): RouteRecord[] ` Get the current list of routes
14
14
15
15
# Basic example
@@ -115,7 +115,7 @@ router.addRoute('ParentRoute', routeRecord)
115
115
116
116
``` ts
117
117
interface addRoute {
118
- (parentName : string | Symbol , route : RouteRecord ): () => void
118
+ (parentName : string | symbol , route : RouteRecord ): () => void
119
119
(route : RouteRecord ): () => void
120
120
}
121
121
```
@@ -126,7 +126,7 @@ Removing a route removes all its children as well. As with `addRoute`, it's nece
126
126
127
127
``` ts
128
128
interface removeRoute {
129
- (name : string | Symbol ) : () => void
129
+ (name : string | symbol ) : void
130
130
}
131
131
```
132
132
@@ -136,7 +136,7 @@ Checks if a route exists:
136
136
137
137
``` ts
138
138
interface hasRoute {
139
- (name : string | Symbol ): boolean
139
+ (name : string | symbol ): boolean
140
140
}
141
141
```
142
142
You can’t perform that action at this time.
0 commit comments