Skip to content
Javascript的sleep函数

山里来了攻城狮 | WILDLION

Welcome.

  • Home
  • IT
  • Server
    • Linux
    • Windows
  • Life
  • Links
  • Contact

Tag: sleep

Javascript的sleep函数

转载自知乎

function sleep(delay) {
    var start = new Date().getTime();
    while (new Date().getTime() < start + delay);
}
Posted on 2017/09/02Author Blogger OwnerCategories ITTags js, sleep5 Comments on Javascript的sleep函数 3,485 views
Contact © 2025 山里来了攻城狮 | WILDLION | sitemap