mirror of
https://github.com/metosin/reitit.git
synced 2025-12-22 18:41:10 +00:00
Update docs for controller and identity
Fixed typos in a sentence about `start`. Also updated the information about `stop` call, looks like it will be called with last controller identity value, not return value of params
This commit is contained in:
parent
2d37311286
commit
42e5746c2f
1 changed files with 3 additions and 3 deletions
|
|
@ -18,9 +18,9 @@ controller identity
|
||||||
|
|
||||||
When you navigate to a route that has a controller, controller identity
|
When you navigate to a route that has a controller, controller identity
|
||||||
is first resolved by calling `identity` function, or by using `parameters`
|
is first resolved by calling `identity` function, or by using `parameters`
|
||||||
declaration, or if neither is set, the identity is `nil`. Next controller
|
declaration, or if neither is set, the identity is `nil`. Next, the controller
|
||||||
is initialized by calling `start` is called with the identity value.
|
is initialized by calling `start` with the controller identity value.
|
||||||
When you exit that route, `stop` is called with the return value of `params.`
|
When you exit that route, `stop` is called with the last controller identity value.
|
||||||
|
|
||||||
If you navigate to the same route with different match, identity gets
|
If you navigate to the same route with different match, identity gets
|
||||||
resolved again. If the identity changes from the previous value, controller
|
resolved again. If the identity changes from the previous value, controller
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue