當你高階函數(forEach、map、…)用習慣之後,往往不想回頭再寫傳統的for ... await Promise.all(arr.map( num => wait(num)));console.log('done') ...
確定! 回上一頁