美文网首页
时间戳和newDate()相互转换

时间戳和newDate()相互转换

作者: 前端Tree | 来源:发表于2020-04-14 10:55 被阅读0次
    //1、15天的时间戳  
     15* 24 * 60 * 60* 1000
    // 2、当前时间+15天的时间戳 
    +new Date() + 15* 24 * 60 * 60* 1000
    3、当前时间+15天的时间戳转换未newDate()
    // new Date(+new Date() + 15* 24 * 60 * 60* 1000)   15天
    

    相关文章

      网友评论

          本文标题:时间戳和newDate()相互转换

          本文链接:https://www.haomeiwen.com/subject/nhrzmhtx.html