js 标准时间转为非标准时间

Thu May 12 2016 08:00:00 GMT+0800 (中国标准时间)标准时间转==>非标准时间 

let date = new Date()
let d = new Date(date);
let datetime=d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() + ' ' + d.getHours() + ':' + d.getMinutes() + ':' + d.getSeconds();
console.log('非标准时间',datetime)

参考文档

https://www.cnblogs.com/gudi/p/8031219.html

posted @ 2020-05-10 18:36  塞巴斯酱  阅读(190)  评论(0编辑  收藏  举报