Skip to main content

RECondition<R extends RuleType = RuleType, C extends string = string>

Defined in: rules-engine/src/types/rulesEngine.ts:19

A condition within a RulesEngine. Each condition has an antecedent (rule group) and an optional consequent. A condition may also itself contain nested conditions.

Extends​

Type Parameters​

Type ParameterDefault type
R extends RuleTypeRuleType
C extends stringstring

Properties​

antecedent​

antecedent: RuleGroupType

Defined in: rules-engine/src/types/rulesEngine.ts:21


conditions?​

optional conditions?: RECondition<RuleType<string, string, any, string, Record<string, any>>, string>[]

Defined in: rules-engine/src/types/rulesEngine.ts:61

Inherited from​

Partial.conditions


consequent?​

optional consequent?: Consequent

Defined in: rules-engine/src/types/rulesEngine.ts:22


defaultConsequent?​

optional defaultConsequent?: Consequent

Defined in: rules-engine/src/types/rulesEngine.ts:62

Inherited from​

Partial.defaultConsequent


disabled?​

optional disabled?: boolean

Defined in: core/src/types/ruleGroups.ts:10

Inherited from​

CommonRuleAndGroupProperties.disabled


evaluationMode?​

optional evaluationMode?: EvaluationMode

Defined in: rules-engine/src/types/rulesEngine.ts:70

How sibling conditions relate to one another when exported. Defaults to "cascade".

  • "cascade": conditions are evaluated in order; a later sibling only fires if all prior siblings' antecedents failed (if/else-if/else semantics).
  • "cumulative": every condition is evaluated independently and any number may fire.

Inherited from​

Partial.evaluationMode


id?​

optional id?: string

Defined in: core/src/types/ruleGroups.ts:9

Inherited from​

CommonRuleAndGroupProperties.id


muted?​

optional muted?: boolean

Defined in: core/src/types/ruleGroups.ts:16

Whether this rule or group is muted. When muted, the rule or group is excluded from query export formats (SQL, JSON, MongoDB, etc.). For groups, muting recursively mutes all children.

Inherited from​

CommonRuleAndGroupProperties.muted


path?​

optional path?: Path

Defined in: core/src/types/ruleGroups.ts:8

Inherited from​

CommonRuleAndGroupProperties.path


caution

API documentation is generated from the latest commit on the main branch. It may be somewhat inconsistent with official releases of React Query Builder.