effect-io-ai

Package: effect
Module: Duration

Duration.DurationValue

Tagged representation of a Duration value.

When to use

Use when modeling or inspecting the exact tagged representation stored in a Duration, including finite millisecond or nanosecond values and infinite sentinels.

Details

A duration is represented as milliseconds, nanoseconds, positive infinity, or negative infinity.

See

Signature

type DurationValue = | { _tag: "Millis"; millis: number }
  | { _tag: "Nanos"; nanos: bigint }
  | { _tag: "Infinity" }
  | { _tag: "NegativeInfinity" }

Source

Since v2.0.0