当前位置 博文首页 > cainiaohhhh的博客:前端时间格式2020-02-11T12:24:18.000+0000
function renderTime(date) {
var dateee = new Date(date).toJSON();
return new Date(+new Date(dateee) + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '')
}
转化成功为:
2020-02-11 12:24:18