How to check if WkWebView finish loading in Objective-C?

前端 未结 3 763
星月不相逢
星月不相逢 2021-01-01 08:12

I want to load HTML pages using WkWebView and I want to show the page just after it\'s finished loading. As long as it\'s loading I would like to show an activity indicator

3条回答
  •  南笙
    南笙 (楼主)
    2021-01-01 09:14

    I think the WKNavigationDelegate's webView:didFinishNavigation: delegate callback is what you're looking for.

    Configure and present your activity indicator when you start to load and then stop and remove it from view when the callback is called.

提交回复
热议问题