Page Contents

Home > @loopback/filter > Condition

Condition type

Condition clause

Signature:

export type Condition<MT extends object> = {
    [P in KeyOf<MT>]?: PredicateComparison<MT[P]> | (MT[P] & ShortHandEqualType);
};

References: KeyOf, PredicateComparison, ShortHandEqualType

Example

{
  name: {inq: ['John', 'Mary']},
  status: 'ACTIVE',
  age: {gte: 40}
}