I am keeping my own back button on the application. since I don't want to enable the browsers back button. ( client requires ). to do this I implemented this code a page:
init(){
history.pushState(null, null, document.URL);
Ember.$(window).on('popstate', function () {
history.pushState(null, null, document.URL);
});
},
it works fine. no issues. But I do have 2 constrain here:
-
I don't want to write the same code to call my application pages. i have number of pages.
-
init
will call only one on controller loads. so, user can go forward and backwards afterinit
action expires.
So simply how to handle this scenario?
Aucun commentaire:
Enregistrer un commentaire