MomentJS - Unix 時間戳(毫秒)



此方法給出了自 Unix 紀元以來的毫秒數。

語法

moment().valueOf();
+moment();

示例 1

var a = moment().valueOf();

輸出

Unix

示例 2

var a = +moment();

輸出

Unix Moment
momentjs_formatting_date_and_time.htm
廣告
© . All rights reserved.