Package: effect
Module: Predicate
Checks whether a value is not null.
When to use
Use when you need a Predicate refinement that filters out null while
preserving other falsy values.
Details
Returns a refinement that excludes null.
Example (Filtering null values)
import { Predicate } from "effect"
const values = [1, null, 2]
const nonNull = values.filter(Predicate.isNotNull)
console.log(nonNull)
See
isNullisNotNullishSignature
declare const isNotNull: <A>(input: A) => input is Exclude<A, null>
Since v2.0.0