Skip to content

Commit

Permalink
docs: addRoutes version
Browse files Browse the repository at this point in the history
  • Loading branch information
posva committed Jan 25, 2021
1 parent c128b60 commit 97d998f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion docs/api/README.md
Expand Up @@ -424,14 +424,16 @@ _DEPRECATED_: use [`route.addRoute()`](#router-addroute) instead.
Signature:
```js
```ts
router.addRoutes(routes: Array<RouteConfig>)
```
Dynamically add more routes to the router. The argument must be an Array using the same route config format with the `routes` constructor option.
### router.addRoute
> New in 3.5.0
Add a new route to the router. If the route has a `name` and there is already an existing one with the same one, it overwrites it.
Signature:
Expand All @@ -442,6 +444,8 @@ addRoute(route: RouteConfig): () => void
### router.addRoute
> New in 3.5.0
Add a new route record as the child of an existing route. If the route has a `name` and there is already an existing one with the same one, it overwrites it.
Signature:
Expand All @@ -452,6 +456,8 @@ addRoute(parentName: string, route: RouteConfig): () => void
### router.getRoutes
> New in 3.5.0
Get the list of all the active route records. **Note only documented properties are considered Public API**, avoid using any other propery e.g. `regex` as it doesn't exist on Vue Router 4.
Signature:
Expand Down

0 comments on commit 97d998f

Please sign in to comment.