Home > @uniformdev/mesh-sdk-react > useSearchAndFilter

useSearchAndFilter() function

Warning: This API is now obsolete.

beta - Search and filter hook

Signature:

Returns:

{ searchTerm: string; setSearchTerm: (term: string) => void; filterVisibility?: boolean; setFilterVisibility: (visible: boolean) => void; filters: Filter; totalResults?: number; allowBindingSearchTerm?: boolean; }

Example

const { searchTerm, setSearchTerm, filterVisibility, setFilterVisibility, filters, setFilters, handleAddFilter, handleResetFilters, handleDeleteFilter, filterOptions, validFilterQuery } = useSearchAndFilter();