Pull to refresh is a popular design pattern that allows users to reload the content of a website, feed, or app without having to navigate away from it.
Developers widely use the Pull-to-refresh pattern to simplify the user experience by allowing them to reload information needed with just one gesture. In addition, the Pull-to-refresh animation can be used as feedback for the user to know their action was being registered.
Especially for iOS WebView apps, Pull to Refresh is an excellent way to refresh your content in any app quickly. Until 2020 we never needed to use our apps before, but it has changed our (developer) life. With Pull to Refresh in WKWebView apps, you can see new content immediately without visually reloading the page every time:
- Get WebViewGold for iOS
- Go to Config.swift, there are many configuration options for pull to refresh:
var pulltorefresh = false // Set to “true” to enable pull to refresh
var pulltorefresh_loadingsigncolour_lightmode = #colorLiteral(red: 0.501960814, green: 0.501960814, blue: 0.501960814, alpha: 1) //Set the colour of the pull to refresh loading sign in light mode
var pulltorefresh_backgroundcolour_lightmode = #colorLiteral(red: 1, green: 1, blue: 1, alpha: 1) //Set the colour of the pull to refresh loading sign in dark mode
var pulltorefresh_loadingsigncolour_darkmode = #colorLiteral(red: 0.501960814, green: 0.501960814, blue: 0.501960814, alpha: 1) //Set the colour of the pull to refresh background in light mode; requires iOS 13 or higher
var pulltorefresh_backgroundcolour_darkmode = #colorLiteral(red: 1, green: 1, blue: 1, alpha: 1) //Set the colour of the pull to refresh background in dark mode; requires iOS 13 or higher