我陷入了困境,UIWebView加载了不同的URL,如何获取每个URL的contentSize ...
- (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary<NSKeyValueChangeKey,id> *)change context:(void *)context {
if (![keyPath isEqualToString:@"contentSize"]) return;
CGSize vWebContentSize = [self.vcWeb.vWeb.wvBaseMain sizeThatFits:CGSizeZero];
self.vcWeb.view.height = vWebContentSize.height;
[self updateContainerContentSize];
}