JavaScript日付getSeconds
getMinutes

getSeconds日付

getTime

秒(0〜59)を返します。

構文

date.getSeconds()

使用例

下記の値を入力するとサンプルに即時反映されます。

const
new
console
getSeconds
const date = new Date();
console.log(date.getSeconds());   // current second (0-59)