fromMillis
Creates a Date from a timestamp in milliseconds.
Use this when receiving a timestamp from a JS-native source
(e.g. Date.now(), performance.timeOrigin). No heuristic — the
input is always treated as milliseconds.
Available since v2.0.0
Import
Section titled “Import”Signature
Section titled “Signature”Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
ms | number | Milliseconds since the Unix epoch |
Returns
Section titled “Returns”Date | null — A valid Date, or null for NaN / non-finite input
