Skip to main content

Helpers

Filter helpers are ready-made functions that will make the process of creating filters easy and quick. These functions can be applied in all three components of the Svelte Filter Library.

createArrayFilterThe function takes filter value as an input and returns a filtered array
createFilterThe function takes filter settings as an input and creates a filter
createFilterRuleCreates a common filtering rule for several input fields
getFilterThe function retrieves a filter configuration object based on the provided filter id and type
getFiltersFetches a list of available filters
getOptionsThe function returns the list of options for a specified field
getOptionsMapThe function extracts filtering options for multiple fields at once