is - test if the value is equal

condition: {
when: 'Foo',
is: 'Bar',
}
// Foo == 'Bar' => true
// Foo == 'Not a Bar' => false

(value: any, config: condition object) => boolean

is also allows to use a custom function. This function receives the value of the when field as the first attribute and the condition config as the second argument.

condition: {
when: 'Foo',
is: (value, config) => calculateAge(value, config) > 18
}