Class

WKBackForwardList

A WKBackForwardList object maintains a list of visited pages used to go back and forward to the most recent page.

Declaration

class WKBackForwardList : NSObject

Overview

A WKBackForwardList object maintains only the list data—it does not perform actual page loads (in other words, it does not make any client requests). If you need to perform a page load, see the load(_:) method in WKWebView to find out how to do this.

Topics

Getting List Items

var backItem: WKBackForwardListItem?

The item immediately preceding the current item, or nil if there isn't one.

var forwardItem: WKBackForwardListItem?

The item immediately following the current item, or nil if there isn't one.

func item(at: Int) -> WKBackForwardListItem?

Returns the item at a specified distance from the current item.

Getting Sublists

var backList: [WKBackForwardListItem]

The portion of the list preceding the current item.

var forwardList: [WKBackForwardListItem]

The portion of the list following the current item.

Relationships

Inherits From

Conforms To

See Also

Back-Forward List

class WKBackForwardListItem

A WKBackForwardListItem object represents a webpage in the back-forward list of a web view.