Friday 15 July 2011

javascript - Marionette appRouter not working with cordova, but regular routing works? -


I am using the merient appraiser for some time in my web based app, now I am using the same boilerplate For which I have created a Cordova app will not make incidents on the Marineette Appraiser controller.

  App.core.vent.bind ('app: start', function (option) {App.core.vent.trigger ('app: log', 'app: start'); If (backbone.history) {app.controller = new controller (); app.ewufters = new router ({controller: App.controller}); App.core.vent.trigger ('app: log', 'app: backbone Start history.); Backbone history.start ();} App.core.vent.trigger ('app: log', 'app: starting and running!');});  

You can see that I pass the controller in the router, then backbone History. Start (); Call This works well in my web-based app.

  module.exports = controller = marriage.controller.product ({initialize: function (option) {warning ('controller is started'); //this.renderView(view) ;}, MainApp: function () {Warning ('hit main app');}});  

on the router

  module. Exports = Router = Merianet Apprauter Extension ({appRoutes: {'': 'mainApp'}});  

Usually this triggers the mainApp on the controller, but nothing happens when using Cordoba.

However, when I use the original router, it triggers

  module.exports = router = merianet Apprauter.extended ({path: {'::' mainApp '}, main app: function () {alert (' main app hit ');}});  

Why is there any such idea, does the mariator react differently because the app file path is different from the standard URL or something else?


No comments:

Post a Comment