📄 tanstack/pacer/latest/docs/reference/interfaces/DebouncerOptions

File: DebouncerOptions.md | Updated: 11/15/2025

Source: https://tanstack.com/pacer/latest/docs/reference/interfaces/DebouncerOptions



TanStack

Pacer v0v0

Search...

+ K

Auto

Log In

TanStack StartRC

Docs Examples GitHub Contributors

TanStack Router

Docs Examples GitHub Contributors

TanStack Query

Docs Examples GitHub Contributors

TanStack Table

Docs Examples Github Contributors

TanStack Formnew

Docs Examples Github Contributors

TanStack DBbeta

Docs Github Contributors

TanStack Virtual

Docs Examples Github Contributors

TanStack Paceralpha

Docs Examples Github Contributors

TanStack Storealpha

Docs Examples Github Contributors

TanStack Devtoolsalpha

Docs Github Contributors

More Libraries

Maintainers Partners Support Learn StatsBETA Discord Merch Blog GitHub Ethos Brand Guide

Documentation

Framework

React logo

React

Version

Latest

Search...

+ K

Menu

Getting Started

Guides

API Reference

Debouncer API Reference

Throttler API Reference

Rate Limiter API Reference

Queue API Reference

Batcher API Reference

Debouncer Examples

Throttler Examples

Rate Limiter Examples

Queue Examples

Batcher Examples

TanStack Query Examples

Framework

React logo

React

Version

Latest

Menu

Getting Started

Guides

API Reference

Debouncer API Reference

Throttler API Reference

Rate Limiter API Reference

Queue API Reference

Batcher API Reference

Debouncer Examples

Throttler Examples

Rate Limiter Examples

Queue Examples

Batcher Examples

TanStack Query Examples

On this page

DebouncerOptions

Copy Markdown

Interface: DebouncerOptions<TFn>
================================

Defined in: debouncer.ts:49

Options for configuring a debounced function

Type Parameters
---------------
### TFn

TFn extends AnyFunction

Properties
----------
### enabled?

ts

optional enabled: boolean | (debouncer) => boolean;


optional enabled: boolean | (debouncer) => boolean;

Defined in: debouncer.ts:55

Whether the debouncer is enabled. When disabled, maybeExecute will not trigger any executions. Can be a boolean or a function that returns a boolean. Defaults to true.


### initialState?

ts

optional initialState: Partial<DebouncerState<TFn>>;


optional initialState: Partial<DebouncerState<TFn>>;

Defined in: debouncer.ts:59

Initial state for the debouncer


### key?

ts

optional key: string;


optional key: string;

Defined in: debouncer.ts:64

A key to identify the debouncer. If provided, the debouncer will be identified by this key in the devtools and PacerProvider if applicable.


### leading?

ts

optional leading: boolean;


optional leading: boolean;

Defined in: debouncer.ts:70

Whether to execute on the leading edge of the timeout. The first call will execute immediately and the rest will wait the delay. Defaults to false.


### onExecute()?

ts

optional onExecute: (args, debouncer) => void;


optional onExecute: (args, debouncer) => void;

Defined in: debouncer.ts:74

Callback function that is called after the function is executed

#### Parameters ##### args

Parameters<TFn>

##### debouncer

Debouncer <TFn>

#### Returns

void


### trailing?

ts

optional trailing: boolean;


optional trailing: boolean;

Defined in: debouncer.ts:79

Whether to execute on the trailing edge of the timeout. Defaults to true.


### wait

ts

wait: number | (debouncer) => number;


wait: number | (debouncer) => number;

Defined in: debouncer.ts:85

Delay in milliseconds before executing the function. Can be a number or a function that returns a number. Defaults to 0ms

Edit on GitHub

React Hooks

DebouncerState

Partners Become a Partner

Code RabbitCode Rabbit CloudflareCloudflare AG GridAG Grid NetlifyNetlify NeonNeon WorkOSWorkOS ClerkClerk ConvexConvex ElectricElectric SentrySentry PrismaPrisma StrapiStrapi UnkeyUnkey

scarf analytics