<TKey, T>
public
first<V>(Closure(T, TKey): bool $predicate, V $default = null): T|V
Gets the first item in the collection that passes the given $predicate. If none was found, this returns the $default value.
$predicate
$default
Nexus\Collection\Collection::first()