effect-io-ai

Package: effect
Module: Types

Types.Contravariant.Type

Extracts the type parameter A from a Contravariant<A>.

When to use

Use to recover the carried type from a contravariant phantom marker.

Example (Extracting the inner type)

import type { Types } from "effect"

type Inner = Types.Contravariant.Type<Types.Contravariant<string>>
// string

See

Signature

type Type<A> = A extends Contravariant<infer U> ? U : never

Source

Since v3.9.0