Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Navigating back is broken with autoInitializePage = false (Cannot call method 'trigger' of undefined) #5284
When navigating away from a jQueryMobile application and then back creates an exception when that application has set
Steps to reproduce:
This stems from the fact that
We're currently using the following monkey-patch for this:
referenced this issue
Mar 5, 2013
The broader issue is that the popstate binding is firing "too early" when returning to the page. I'm going to have to work on this one for a bit.
That fits with your hack since you're just killing the navigation when the pageContainer hasn't been created.
There's a fundamental issue with delaying the page initialization and supporting popstate. The popstate that's fired when returning from an external URL contains information about how the page should be initialized, so delaying the initialization means we need to store that info until it happens.