effect-io-ai

Package: effect
Module: Tuple

Tuple.getFirst

Return the first element from a tuple with two elements.

Example

import * as assert from "node:assert"
import { getFirst } from "effect/Tuple"

assert.deepStrictEqual(getFirst(["hello", 42]), "hello")

Signature

declare const getFirst: <L, R>(self: readonly [L, R]) => L

Source

Since v2.0.0