Skip to content

Commit

Permalink
[DOC release] include QP-only transitionTo info
Browse files Browse the repository at this point in the history
Both `Route.transitionTo` and `RouterService.transitionTo` support
query-params-only transitions, where the caller invokes the method
like `transitionTo({ queryParams: { ... } })`.

(cherry picked from commit f63c27e)
  • Loading branch information
chriskrycho authored and kategengler committed Feb 25, 2020
1 parent 8a3ebdc commit bdd32b1
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
7 changes: 4 additions & 3 deletions packages/@ember/-internals/routing/lib/services/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,12 @@ export default class RouterService extends Service {
```
@method transitionTo
@param {String} routeNameOrUrl the name of the route or a URL
@param {...Object} models the model(s) or identifier(s) to be used while
@param {String} [routeNameOrUrl] the name of the route or a URL
@param {...Object} [models] the model(s) or identifier(s) to be used while
transitioning to the route.
@param {Object} [options] optional hash with a queryParams property
containing a mapping of query parameters
containing a mapping of query parameters. May be supplied as the only
parameter to trigger a query-parameter-only transition.
@return {Transition} the transition object associated with this
attempted transition
@public
Expand Down
7 changes: 4 additions & 3 deletions packages/@ember/-internals/routing/lib/system/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -785,11 +785,12 @@ class Route extends EmberObject implements IRoute {
```
@method transitionTo
@param {String} name the name of the route or a URL
@param {...Object} models the model(s) or identifier(s) to be used while
@param {String} [name] the name of the route or a URL.
@param {...Object} [models] the model(s) or identifier(s) to be used while
transitioning to the route.
@param {Object} [options] optional hash with a queryParams property
containing a mapping of query parameters
containing a mapping of query parameters. May be supplied as the only
parameter to trigger a query-parameter-only transition.
@return {Transition} the transition object associated with this
attempted transition
@since 1.0.0
Expand Down

0 comments on commit bdd32b1

Please sign in to comment.