RunKit + npm: luxon

node v18.11.0
endpointsharetweet
const luxon = require("luxon") const clipTime = luxon.DateTime.fromJSDate(new Date('2022-08-25T09:00:00.000-04:00')) const nowTime = luxon.DateTime.fromJSDate(new Date('2022-08-25T09:01:00.000-04:00')) const seconds = nowTime.setZone('UTC').toUnixInteger() - clipTime.setZone('UTC').toUnixInteger() console.log(seconds)
Created from: https://npm.runkit.com/luxon
Loading…