core.countwhere | Medplum

countWhere() function

Signature:

export declare function countWhere<T>(items: Iterable<T>, fn: (value: T) => boolean): number;

Parameters [​](/content/docs/sdk/core.countwhere#parameters "Direct link to Parameters"/index.html)

Parameter Type Description
items Iterable
fn (value: T) => boolean

Returns:

number