ColumnFilterState more specific types

  const [columnFiltersState, setColumnFiltersState] = useState<ColumnFiltersState>([]);
  const [columnSearchState, setColumnSearchState] = useState<ColumnFiltersState>([]);
  ...
...


hi, we have a custom hook that manages manual pagination, sorting, filtering...
For the types we use the RT8 ColumnFiltersState, which is { id: string, value: unknown}[].


For the value we use string[]. But we have to add 'as string[]' everywhere. Is there a cleaner way to get around this? Would omitting work here?
Was this page helpful?