第一种和第二种是获取了当前毫秒的时间戳 ,最后一种获取的时间戳是把毫秒改成000显示
//方法一
let timestamp = (new Date()).getTime();
console.log(timestamp); //1555466794193
//方法二
let timestamp2 = (new Date()).valueOf();
console.log(timestamp2); //1555466794195
//方法三
let timestamp3 = Date.parse(new Date());
console.log(timestamp3);//1555466794000