Open
Description
Version
3.0.2
Reproduction link
Steps to reproduce
- Read the API documentation at https://router.vuejs.org/api/#routes for the
routes
router construction options and see that theroutes
field is designated as an array ofRouteConfig
(with an accompanying definition of that type). - Read the API documentation at https://router.vuejs.org/api/#route-object-properties for
$route.matched
and see that the copy of the aforementionedroutes
option is now designated as an array ofRouteRecord
(with not definition of that type)
What is expected?
If the latter is a copy of the former, it should be expected that it should be the same object type or that an explicit relationship between the 2 types be mentioned in the API doc as a canonical definition.
What is actually happening?
There is no canonical definition of what a RouteRecord
type is, we only have an example that denotes the array of RouteConfig
and we don't understand why copying a type does not result of an instance of the same type.