Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Welcome, Guest. Please login or register.
October 19, 2017, 08:22:12 PM
Home Help Search Login Register
News: Please DM @puremvc on Twitter to gain forum access. Spambots are why we can't have nice things.
Pages: [1]
Print
Author Topic: equivalent of initializeModel and initializeView in ApplicationFacade  (Read 2907 times)
saad
Sr. Member
****
Posts: 65


View Profile
« on: February 13, 2014, 02:20:40 PM »

is there an equivalent of initializeModel and initializeView in ApplicationFacade for the JS port? (http://puremvc.org/pages/docs/AS3/standard/framework_asdoc/org/puremvc/as3/patterns/facade/Facade.html)

I see a startup function in the demo examples that registers the commands and then fires the notification instead of initializeController?

https://github.com/PureMVC/puremvc-js-demo-reversetext/blob/master/src/ApplicationFacade.js

how this works out in the JS port?
Logged
puremvc
Global Moderator
Hero Member
*****
Posts: 2871



View Profile WWW
« Reply #1 on: March 06, 2014, 02:47:57 PM »

The initializeController() method is present, but it was deemed just as easy for the startup() method to register the StartupCommand and then trigger it.

In this particular application, the methodology of putting the registration of commands into a sub command of StatupCommand was implemented, which is an alternate way of doing things that reduces the number of classes the Facade has to know.
Logged
Pages: [1]
Print
Jump to: