Interface GlobalFilterOptions<Data>

Type interface for filtering options.

Type Parameters

Hierarchy

Custom Component Properties

Component?: GlobalFilterComponent<Data>

Global filter component rendered for in table. This overrides the fallback text-input-field.

Other Properties

autoResetGlobalFilter?: boolean

Reset filtering when data is changed.

Default

true

defaultVisibleGlobalFilter?: boolean

Should the Global Filter be visible by default.

Default

false

disableGlobalFilter?: boolean

Disable global filtering for table.

Default

false

filterTypes?: Record<string, FilterType<Data>>

Allows overriding or adding additional filter types. If "globalFilter" type isn't found on this object, it will default to using the built-in filter types. Must be memoised.

globalFilter?: string | ((rows: Row<Data>[], columnIds: IdType<Data>[], globalFilterValue: string) => Row<Data>[])

Default

"text"

initialState?: UseGlobalFiltersState<Data>

Initial settings of global filter.

Example

{ globalFilter: {} }
manualGlobalFilter?: boolean

Manual filtering with custom logic, eg. server-side. Enables filter detection functionality, but does not automatically perform row filtering

Default

false

onStateChange?: StateChangeHandler<UseGlobalFiltersState<Data>>

Callback executed when columns are sorted. The function must be wrapped in useCallback hook.

Generated using TypeDoc