Skip to content

Commit

Permalink
[DOC RouteInfo] Fix grammar, spelling, and formatting
Browse files Browse the repository at this point in the history
(cherry picked from commit 8693674)
  • Loading branch information
tansongyang authored and kategengler committed Mar 25, 2019
1 parent b179dfd commit fff729a
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
4 changes: 2 additions & 2 deletions packages/@ember/-internals/routing/lib/services/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -293,8 +293,8 @@ if (EMBER_ROUTING_ROUTER_SERVICE) {
});
},

/**
A RouteInfo that represents the current leaf route.
/**
A `RouteInfo` that represents the current leaf route.
It is guaranteed to change whenever a route transition
happens (even when that transition only changes parameters
and doesn't change the active route)
Expand Down
12 changes: 7 additions & 5 deletions packages/@ember/-internals/routing/lib/system/route-info.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
/**
The ordered list of the names of the params
required for this route. It will contain the same
strings as Object.keys(params), but here the order
strings as `Object.keys(params)`, but here the order
is significant. This allows users to correctly pass
params into routes programmatically.
@property {Array} paramNames
Expand Down Expand Up @@ -153,9 +153,9 @@
*/

/**
The values of the route's parametes. These are the
The values of the route's parameters. These are the
same params that are received as arguments to the
route's model hook. Contains only the parameters
route's `model` hook. Contains only the parameters
valid for this route, if any (params for parent or
child routes are not merged).
@property {Object} params
Expand All @@ -182,7 +182,7 @@
*/

/**
A reference to the parent route's RouteInfo.
A reference to the parent route's `RouteInfo`.
This can be used to traverse upward to the topmost
`RouteInfo`.
@property {RouteInfo|null} parent
Expand All @@ -191,7 +191,7 @@
*/

/**
A reference to the child route's RouteInfo.
A reference to the child route's `RouteInfo`.
This can be used to traverse downward to the
leafmost `RouteInfo`.
@property {RouteInfo|null} child
Expand All @@ -202,7 +202,9 @@
of `RouteInfo`s from the topmost to leafmost.
Returns the first `RouteInfo` in the linked list
for which the callback returns true.
*/

/**
This method is similar to the `find()` method
defined in ECMAScript 2015.
Expand Down
6 changes: 3 additions & 3 deletions packages/@ember/-internals/routing/lib/system/transition.ts
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
* This property is a `RouteInfo` object that represents
* where the router is transitioning to. It's important
* to note that a `RouteInfo` is a linked list and this
* property is simply represents leafmost route.
* property represents the leafmost route.
* @property {RouteInfo|RouteInfoWithAttributes} to
* @public
* @category ember-routing-router-service
Expand All @@ -148,8 +148,8 @@
* This property is a `RouteInfo` object that represents
* where transition originated from. It's important
* to note that a `RouteInfo` is a linked list and this
* property is simply represents head node of the list.
* In the case of an initial render, from will be set to
* property represents the head node of the list.
* In the case of an initial render, `from` will be set to
* `null`.
* @property {RouteInfoWithAttributes} from
* @public
Expand Down

0 comments on commit fff729a

Please sign in to comment.