Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WKWebView 使用 AutoLayout 初次加载显示不全 #1590

Open
Jasonjunjie opened this issue Aug 4, 2023 · 0 comments
Open

WKWebView 使用 AutoLayout 初次加载显示不全 #1590

Jasonjunjie opened this issue Aug 4, 2023 · 0 comments
Labels

Comments

@Jasonjunjie
Copy link

描述bug
WKWebView 使用 AutoLayout 初次加载显示不全

必现/偶发?
必现

//    self.webView = [[WKWebView alloc] initWithFrame:self.view.bounds];
//    self.webView.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight;
    
    UIView *topView = [[UIView alloc] initWithFrame:CGRectZero];
    topView.backgroundColor = UIColor.yellowColor;
    [self.view addSubview:topView];
    [topView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.right.mas_equalTo(0);
        make.top.mas_equalTo(0);
        make.height.mas_equalTo(60);
    }];
    
    self.webView = [[WKWebView alloc] initWithFrame:CGRectZero];
    
    [self.view addSubview:self.webView];
    self.webView.navigationDelegate = self;
    
    [self.webView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.right.mas_equalTo(0);
        make.top.mas_equalTo(topView.mas_bottom);
        make.bottom.mas_equalTo(0);
    }];

截图
IMG_7521

运行环境

  • iPhone12
  • iOS16.5
  • Xcode14.3.1

额外的
最好能提供出现bug的Demo
MJRefreshExample.zip

@Jasonjunjie Jasonjunjie added the bug label Aug 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant