This video is available to students only

Other customizations

Changing or removing certain components of the query builder

Other customizations#

Removing the Add Group button#

One thing you may want to do is remove the ability of users to create sub-groups of rules, limiting them to creating flat, single-level rule sets, for some business or technical reason. You can easily remove the "Add Group" button by assigning it a function that returns null instead of a JSX element.

CombinatorSelector as radio button#

As an example of completely replacing a default component, we can change the combinator selector from a drop-down menu to radio buttons. We can copy the ValueSelector component from the react-querybuilder source code, then modify it. Create a new file called CombinatorSelector.tsx in the client/src/ folder.

No discussions yet