3 ms·
The current best minimalist practice is to use LayoutManager have your router be the super-orchestrator that makes sure all the models are loaded (use the cachi
by BadassFractal 13y ago
The current best minimalist practice is to use LayoutManager have your router be the super-orchestrator that makes sure all the models are loaded (use the caching plugin, very convenient), and instantiates the necessary nested views based on the route. Now that react.js is getting popular, it also might be worth looking into swapping LayoutManager out for it.
- AdrianRossouw 13y agoOne one of my recent projects I found that using a state machine (http://statejs.org http://statejs.org in this case) made the whole router malarky much easier to deal with. It fires methods on transition etc, so you can make it load something when you go to this page, make it change this dialog when it goes to that. The router was just something that changed the url when the application state changed.