Plumile JS API
    Preparing search index...

    Function setFilter

    • Sets or unsets a specific operator value on a field while preserving reference equality when nothing changes.

      Type Parameters

      • S extends Readonly<Record<string, FieldDescriptor>>
      • F extends string | number | symbol
      • O extends string | number | symbol

      Parameters

      • filters: Readonly<InferFilters<S>>

        Current filters object that will be treated as immutable input.

      • _schema: S

        Schema reference (reserved for future validation hooks).

      • field: F

        Field key to update.

      • operator: O

        Operator name to set or remove.

      • value: NonNullable<InferFilters<S>[F]>[O] | undefined

        New operator value; pass undefined to remove it.

      Returns InferFilters<S>