Skip to main content

remove()

remove<RG>(query: RG, path: Path): RG

Defined in: packages/react-querybuilder/src/utils/queryTools.ts:200

Removes a rule or group from a query.

Type Parameters

Type Parameter
RG extends RuleGroupTypeAny

Parameters

ParameterTypeDescription
queryRGThe query to update.
pathPathPath of the rule or group to remove.

Returns

RG

The new query with the rule or group removed.


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.