Skip to main content

UseQueryBuilderSetup<RG, F, O, C>

UseQueryBuilderSetup<RG, F, O, C>: { combinators: WithUnknownIndex<BaseOption<string> & FullOption<string>>[] | OptionGroup<WithUnknownIndex<BaseOption<string> & FullOption<string>>>[]; createRule: () => GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>; createRuleGroup: (independentCombinators?: boolean) => RG; fieldMap: FullOptionMap<FullField<string, string, string, Option<string>, Option<string>>, GetOptionIdentifierType<F>>; fields: FullOptionList<F>; getRuleDefaultValue: <RT>(r: RT) => any; qbId: string; rqbContext: UseMergedContextReturn<F, GetOptionIdentifierType<O>>; } & RemoveNullability<{ getInputTypeMain: QueryBuilderProps<RG, F, O, C>["getInputType"]; getRuleDefaultOperator: QueryBuilderProps<RG, F, O, C>["getDefaultOperator"]; getValueEditorTypeMain: QueryBuilderProps<RG, F, O, C>["getValueEditorType"]; getValueSourcesMain: QueryBuilderProps<RG, F, O, C>["getValueSources"]; }> & { getOperatorsMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getOperators"]>>) => FullOptionList<O>; getValuesMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getValues"]>>) => FullOptionList<Option>; }

Type declaration

combinators

combinators: WithUnknownIndex<BaseOption<string> & FullOption<string>>[] | OptionGroup<WithUnknownIndex<BaseOption<string> & FullOption<string>>>[]

createRule()

createRule: () => GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>

Returns

GetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>

createRuleGroup()

createRuleGroup: (independentCombinators?: boolean) => RG

Parameters

ParameterType
independentCombinators?boolean

Returns

RG

fieldMap

fieldMap: FullOptionMap<FullField<string, string, string, Option<string>, Option<string>>, GetOptionIdentifierType<F>>

fields

fields: FullOptionList<F>

getRuleDefaultValue()

getRuleDefaultValue: <RT>(r: RT) => any

Type Parameters

Type ParameterDefault type
RT extends RuleTypeGetRuleTypeFromGroupWithFieldAndOperator<RG, F, O>

Parameters

ParameterType
rRT

Returns

any

qbId

qbId: string

rqbContext

rqbContext: UseMergedContextReturn<F, GetOptionIdentifierType<O>>

Type declaration

getOperatorsMain()

getOperatorsMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getOperators"]>>) => FullOptionList<O>

Parameters

ParameterType
...pParameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getOperators"]>>

Returns

FullOptionList<O>

getValuesMain()

getValuesMain: (...p: Parameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getValues"]>>) => FullOptionList<Option>

Parameters

ParameterType
...pParameters<NonNullable<QueryBuilderProps<RG, F, O, C>["getValues"]>>

Returns

FullOptionList<Option>

Type Parameters

Type Parameter
RG extends RuleGroupTypeAny
F extends FullField
O extends FullOperator
C extends FullCombinator

Defined in

packages/react-querybuilder/src/components/QueryBuilder.useQueryBuilderSetup.ts:59


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.