function sleep(numberMillis) { var now = new Date(); var exitTime = now.getTime() + numberMillis; while (true) { now = new Date(); if (now.getTime() > exitTime) return; } }
原文地址:https://www.cnblogs.com/chenyanbin/p/12361443.html
时间: 2024-10-04 11:38:10