Skip to content

Commit 52c6504

Browse files
author
Jen Weber
authored
Merge pull request #173 from donofriov/feature/update-controller-docs-with-query-params
Add Query Params to Controller Guide (#163)
2 parents 64320d1 + ffd8b7c commit 52c6504

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

guides/v3.4.0/controllers/index.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ The model is passed from the Route to the Controller by default using the [`setu
66

77
A Controller is usually paired with an individual Route of the same name.
88

9+
[Routing Query Parameters](https://guides.emberjs.com/release/routing/query-params/) should be defined within a controller.
10+
911
### Defining a Controller
1012

1113
We only need to generate a Controller file if we want to customize the properties or provide any actions to the Route. If we have no customizations, Ember will provide a default Controller instance for us at run time.
@@ -95,11 +97,11 @@ We can see that if the property `isExpanded` is toggled to true, we will show th
9597
### Common questions
9698

9799
###### Should we use controllers in my application? I've heard they're going away!
98-
100+
99101
Yes! Controllers are still an integral part of an Ember application architecture, and generated by the framework even if you don't declare a Controller module explicitly.
100102

101103
###### When should we create a Controller?
102104

103105
* We want to pass down actions or variables to share with a Route’s child components
104106
* We have a computed property that depends on the results of the model hook
105-
* We need to support query parameters
107+
* We need to support query parameters

0 commit comments

Comments
 (0)