# Function removeFilters
removeFilters(
dashboard
,filtersToRemove
):DashboardProps
Creates a new dashboard instance with multiple filters removed.
This function removes all filters with the same GUID as the provided filters from the dashboard's filters. This function does not modify the original dashboard; instead, it returns a new dashboard with the updated filters.
# Parameters
Parameter | Type | Description |
---|---|---|
dashboard | DashboardProps | The original dashboard (DashboardProps ) from which the specified filters are removed. |
filtersToRemove | Filter [] | An array of filters to remove. |
# Returns
A new dashboard instance with the specified filters removed.
# Example
Remove multiple filters from a dashboard.
const existingDashboard: DashboardProps = {...};
const filtersToRemove: Filter[] = [{...}, {...}, ...];
const updatedDashboard = removeFilters(existingDashboard, filtersToRemove);