How can I get the progress of a downloading [removed]?

后端 未结 2 782
你的背包
你的背包 2020-12-02 17:03

Let\'s say, for example, I\'m creating a game. I have a small script whose job is to load all the assets and present a progress bar to the user while the assets load.

<
2条回答
  •  臣服心动
    2020-12-02 17:44

    You might like to have a look at How to show loading status in percentage for ajax response?

    It is to see the status of an AJAX download. Since you are loading a script, it might not be the best way to get the file but it could work. You would then need to put the content received by the ajax call somewhere to execute, and eval is not recommended.

提交回复
热议问题