Skip to main content

@rbxts/expect > Filter

Filter type

Callback for deciding if a value satisfies a condition.

Signature:

type Filter<T = unknown> = (value: T) => boolean;

Example

const isEven: Filter<number> = (value) => value % 2 === 0;