Parse the timestamp from a UUID v7. UUID v7 stores a Unix timestamp in milliseconds in the first 48 bits.
the UUID v7 string to parse
the timestamp as a Date
import { parseUUID7Timestamp } from "@trashpanda001/helpers/string"parseUUID7Timestamp("01234567-90ab-7fff-ffff-ffffffffffff")// 2009-08-23T03:58:18.283Z Copy
import { parseUUID7Timestamp } from "@trashpanda001/helpers/string"parseUUID7Timestamp("01234567-90ab-7fff-ffff-ffffffffffff")// 2009-08-23T03:58:18.283Z
Parse the timestamp from a UUID v7. UUID v7 stores a Unix timestamp in milliseconds in the first 48 bits.