samedi 31 mars 2018

Ember: When is a controller instantiated

I was going through the Ember tutorial in https://guides.emberjs.com/v3.0.0/routing/preventing-and-retrying-transitions/#toc_storing-and-retrying-a-transition

Here, in order to store and retry a transition, they're setting an instance property previousTransition in loginController.

How does controllerFor work? Will loginController not be instantiated again when routed to the corresponding route?

How is previousTransition persisted so that they're accessing it in loginController?

I'm new to Ember. Could someone throw some light on this?




Aucun commentaire:

Enregistrer un commentaire