TWSViewState
A state holder to hold the state for the WebView.
NOTE: This class is a modified version of the original Accompanist WebView state holder. Modifications made include:
Added custom error tracking with
customErrorsForCurrentRequest
.Removed some of the properties that were unused in our implementation.
Properties
The content being loaded by the WebView
The URL of the most recently visited page in the browsing history. This is updated as the user navigates, including when a page is reloaded. Used in Single Page Applications (SPA) to reflect URL changes.
A list for errors captured in the last load. Reset when a new page is loaded. Errors could be only from the main page.
The URL of the initial page that started loading.
The URL of the last page that started loading. This is updated when a new page load begins.
Whether the WebView is currently loading resources and loading its main frame (along with progress). See TWSLoadingState
The saved view state from when the view was destroyed last. To restore state, use the navigator and only call loadUrl if the bundle is null.
A list for errors captured in the last load. Reset when a new page is loaded. Errors could be from any resource (iframe, image, etc.), not just for the main page.