let timeArrays = new Array(24).fill('').map((item, index) => (index < 10 ? '0' + index : index + "")); // ['00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23']
JS 生成一天24个小时的数组
7 min read