Mfilter
Bun

method

url.URLSearchParamsIterator.filter

filter<S>(
predicate: (value: T, index: number) => value is S
): IteratorObject<S, undefined, unknown>;

Creates an iterator whose values are those from this iterator for which the provided predicate returns true.

@param predicate

A function that accepts up to two arguments to be used to test values from the underlying iterator.

predicate: (value: T, index: number) => unknown
): IteratorObject<T, undefined, unknown>;

Creates an iterator whose values are those from this iterator for which the provided predicate returns true.

@param predicate

A function that accepts up to two arguments to be used to test values from the underlying iterator.