UNPKG

@effect-ts/system

Version:

Effect-TS is a zero dependency set of libraries to write highly productive, purely functional TypeScript at scale.

13 lines (10 loc) 329 B
// ets_tracing: off import type * as Tp from "../Collections/Immutable/Tuple/index.js" import { access } from "./core.js" /** * Returns an effectful function that extracts out the first element of a * tuple. */ export function first<A>(__trace?: string) { return access((_: Tp.Tuple<[A, unknown]>) => _.get(0), __trace) }