Skip to content
Browse files

1.0b1 works with domcache = true and removing prev pages on pageshow

  • Loading branch information...
1 parent 957fd3b commit ed327242b73af45f5696bf7947c6ccf15d0d51b9 @dgeb committed Oct 6, 2011
Showing with 5 additions and 1 deletion.
  1. +4 −0 README.md
  2. +1 −1 app.js
View
4 README.md
@@ -5,6 +5,10 @@ https://github.com/jquery/jquery-mobile/issues/2520
Please see the branches of this project to see the different behaviour.
+## jquery-mobile 1.0b1
+
+In this branch, pages are cached, but are removed from the cache as soon as another one is shown. This strategy works well.
+
## MIT LICENSE
Copyright (c) 2011 Dan Gebhardt
View
2 app.js
@@ -2,7 +2,7 @@ $(document).bind("mobileinit", function() {
$.mobile.page.prototype.options.domCache = true;
});
-$('div').live('pageshow',function(event, ui) {
+$(document).bind('pageshow',function(event, ui) {
if (ui.prevPage) ui.prevPage.remove();
});

0 comments on commit ed32724

Please sign in to comment.
Something went wrong with that request. Please try again.