Reputation: 1284
I have boiled down my issue to a very simple scenario and it appears to be with iOS 9+ and UIWebView with a website that has lots of page loads (like you would get from navigating).
I followed this tutorial (http://conecode.com/news/2011/05/ios-tutorial-creating-a-web-view-uiwebview/) to build a simple iOS app with a UIWebView. I pointed the UIWebView at a static html that looks like what I have at the bottom.
I then refreshed the page with the button (or the script that does it automaticly) and eventually the app grows slower and slower (usually around 50-80 refreshes). I have the list in the page for demonstration because it allows you to scroll, which highlights the issue much sooner.
Any help or direction for me to look into resolving this issue?
<!DOCTYPE html>
<html lang="en">
<head></head>
<body>
<FORM><INPUT id="demo" TYPE="button" onClick="history.go(0)" VALUE="refresh"></FORM>
<ul data-role="listview" >
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
<li>This is an Item</li>
</ul>
<script>
var elem = document.getElementById("demo");
elem.value = Date();
location.reload();
</script>
</body>
</html>
Upvotes: 7
Views: 1582
Reputation: 2126
Maybe a memory issue.
Watch the Memory Report (enlarge with double click) in Xcode while running the project and reloading/navigating the UIWebView.
If it is growing, try to delete the UIWebViews cache
Upvotes: 2