• Type Parameters

    Parameters

    • collectionId: string

      The ID of the collection to increment value.

    • itemId: ItemID

      ItemID to filter the _id field when performing the operation.

    • propertyName: Extract<keyof CItem, string>

      Property name for the increment field.

    • value: number

      Increment current value by that much. (If you set it to 10 it will add +10)

    • Optionaloptions: WeivDataOptions

      An object containing options to use when processing this operation.

    Returns Promise<CItem | null>

    Fulfilled - Updated item. Rejected - The error caused the rejection.

    You can use increment function to increment the value of a filed in an item. (Negative values are possible too)