Skip to main content

createRuleGroup()

createRuleGroup<C>(__namedParameters: CreateRuleGroupOptions<C>, independentCombinators?: boolean): RuleGroupTypeAny

Defined in: packages/core/src/utils/ruleFactory.ts:102

Creates a group from the given configuration. Pass true for independentCombinators to omit the combinator property.

The group's own id is generated before any contained rule's, matching the order the QueryBuilder component has always used. This is observable when idGenerator is deterministic, as it often is in tests.

Type Parameters

Type ParameterDefault type
C extends FullCombinatorFullCombinator

Parameters

ParameterType
__namedParametersCreateRuleGroupOptions<C>
independentCombinators?boolean

Returns

RuleGroupTypeAny


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.