Load multiple wkwebview at the same time.

So my question is simple, but is it possible to load multiple wkwebviews at the same time,

so all of them loads correctly?

If I try to do it as below, some of wkwebviews stop loading in the middle or will not load at all (blank).

I'm not doing any UI interactions, just waiting for them to load.


Example:

1. [wkwebviewA loadRequest:x]

2. [wkwebviewB loadRequest:x]

3. [wkwebviewC loadRequest:x]

4. didFinishNavigation (A), no error, wkwebview loads completly

5. didFinishNavigation (B), no error, wkwebview blank

6. didFinishNavigation (C), no error, wkwebview loads partly


However, if I do it like this, everything works fine.

1. [wkwebviewA loadRequest:x]

2. didFinishNavigation (A), no error, wkwebview loads completly

3. [wkwebviewB loadRequest:x]

4. didFinishNavigation (B), no error, wkwebview loads completly

5. [wkwebviewC loadRequest:x]

6. didFinishNavigation (C), no error, wkwebview loads completly


If it's technically possible to load multiple wkwebviews safely, then I guess it's just a bug in my app,

but please let me know.


Thanks

Replies

This is possible. Restoring 100 tabs in Safari, for example, loads 100 WKWebViews at the same time.

And the WebKit project has multiple tools that do the same.

To learn more about what's going on in your code, we'll need to see more of your code.