msedgewebview2 show slowly first time in cold start.

youqiang_wu 0 Reputation points
2023-02-28T12:33:47.94+00:00

I am using Microsoft Edge WebView2 replacing the CEF for showing page in my app. but i found that the web page shows slowly first time in cold start.( about 7-8s) After analyzing for a period of time, it is basically confirmed that it is caused by file io reading and writing. Especially when running, generate a EWebView folder, see the screenshot below link for details.

https://drive.google.com/file/d/1OrkOiK7YI6NHbwWNxC5VFqXQ91-3TaIX/view?usp=share_link

now Is there any way to speed up the webpage display?

Microsoft Edge | Microsoft Edge development
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Anonymous
    2023-03-01T08:54:34.3+00:00

    Hi @youqiang_wu

    First, the creation of EBWebView folder at first time is expected behavior. It's the user data folder.

    Second, WebView2 initialization is dependent on machine performance, so there's no one time that it's expected to run within.

    I have tested and it takes normal time on my machine when I open a WebView2 app for the first time. If it only takes a long time at first time cold start on I/O operations, it has high possibility to be related with your computer hardware like hard disk.

    For more information, you can also refer to this same issue on GitHub.


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Regards,

    Yu Zhou


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.