Skip to content

epochToDate

epochToDate(epoch, genesisTimestamp): Date

Defined in: packages/synapse-core/src/utils/epoch.ts:14

Convert a Filecoin epoch to a JavaScript Date

Parameter Type Description
epoch number The epoch number to convert
genesisTimestamp number The genesis timestamp of the chain in seconds (Unix timestamp)

Date

Date object representing the epoch time