TanStack
Store v0v0
Log In
StartRC
StartRC
Router
Router
Query
Query
Table
Table
DBbeta
DBbeta
AIalpha
AIalpha
Formnew
Formnew
Virtual
Virtual
Pacerbeta
Pacerbeta
Hotkeysalpha
Hotkeysalpha
Storealpha
Storealpha
Devtoolsalpha
Devtoolsalpha
CLIalpha
CLIalpha
Intentalpha
Intentalpha
More Libraries
More Libraries
BuilderAlpha
BuilderAlpha
Blog
Blog
Maintainers
Maintainers
Partners
Partners
Showcase
Showcase
LearnNEW
LearnNEW
Stats
Stats
YouTube
YouTube
Discord
Discord
Merch
Merch
Support
Support
GitHub
GitHub
Ethos
Ethos
Tenets
Tenets
Brand Guide
Brand Guide
Docs
CloudflareCloudflare
RailwayRailway
CodeRabbitCodeRabbit
SerpAPISerpAPI
OpenRouterOpenRouter
ClerkClerk
WorkOSWorkOS
NetlifyNetlify
AG GridAG Grid
ElectricElectric
PrismaPrisma
SentrySentry
UnkeyUnkey
CloudflareCloudflare
RailwayRailway
CodeRabbitCodeRabbit
SerpAPISerpAPI
OpenRouterOpenRouter
ClerkClerk
WorkOSWorkOS
NetlifyNetlify
AG GridAG Grid
ElectricElectric
PrismaPrisma
SentrySentry
UnkeyUnkey
Menu
  • Home
  • Blog
  • Frameworks
  • Contributors
  • NPM Stats
  • GitHub
  • YouTube
  • Discord
Getting Started
  • Overview
  • Installation
  • Quick Start
  • Quick Start
API Reference
  • Core API Reference
  • React Hooks
Store API Reference
  • Store
  • ReadonlyStore
  • Atom
  • AtomOptions
  • BaseAtom
  • InternalBaseAtom
  • InternalReadonlyAtom
  • InteropSubscribable
  • Readable
  • ReadonlyAtom
  • StoreActionsApi
  • Subscribable
  • Subscription
  • AnyAtom
  • Observer
  • Selection
  • StoreAction
  • StoreActionMap
  • StoreActionsFactory
  • batch
  • createAsyncAtom
  • createAtom
  • createStore
  • flush
  • shallow
  • toObserver
  • createStoreContext
  • useCreateAtom
  • useCreateStore
  • useSelector
  • useSetValue
  • useAtom
  • useStoreActions
  • _useStore (experimental)
  • useStore (deprecated)
  • UseSelectorOptions
Examples
  • Simple
  • Atoms
  • Stores
  • Store Actions
  • Store Context
Menu
  • Home
  • Blog
  • Frameworks
  • Contributors
  • NPM Stats
  • GitHub
  • YouTube
  • Discord
Getting Started
  • Overview
  • Installation
  • Quick Start
  • Quick Start
API Reference
  • Core API Reference
  • React Hooks
Store API Reference
  • Store
  • ReadonlyStore
  • Atom
  • AtomOptions
  • BaseAtom
  • InternalBaseAtom
  • InternalReadonlyAtom
  • InteropSubscribable
  • Readable
  • ReadonlyAtom
  • StoreActionsApi
  • Subscribable
  • Subscription
  • AnyAtom
  • Observer
  • Selection
  • StoreAction
  • StoreActionMap
  • StoreActionsFactory
  • batch
  • createAsyncAtom
  • createAtom
  • createStore
  • flush
  • shallow
  • toObserver
  • createStoreContext
  • useCreateAtom
  • useCreateStore
  • useSelector
  • useSetValue
  • useAtom
  • useStoreActions
  • _useStore (experimental)
  • useStore (deprecated)
  • UseSelectorOptions
Examples
  • Simple
  • Atoms
  • Stores
  • Store Actions
  • Store Context
AI/LLM: This documentation page is available in plain markdown format at/store/v0/docs/reference/functions/batch.md
Store API Reference

batch

Function: batch()#

ts
function batch(fn): void;
function batch(fn): void;

Defined in: atom.ts:62

Parameters#

fn#

() => void

Returns#

void

Edit on GitHub
PreviousStoreActionsFactory
NextcreateAsyncAtom

On this page

  • Function: batch()
  • Parameters
  • fn
  • Returns
Blog
@Tan_Stack on X.com
@TannerLinsley on X.com
GitHub
YouTube
Nozzle.io - Keyword Rank Tracker
Ethos
Tenets
Privacy Policy
Terms of Service
© 2026 TanStack LLC
PartnersBecome a Partner
Gold
CloudflareCloudflare
RailwayRailway
CodeRabbitCodeRabbit
Silver
SerpAPISerpAPI
WorkOSWorkOS
ClerkClerk
AG GridAG Grid
NetlifyNetlify
OpenRouterOpenRouter
Bronze
PrismaPrisma
UnkeyUnkey
ElectricElectric
SentrySentry
TanStack Start

Full-stack Framework powered by TanStack Router for React and Solid

Explore Start →
TanStack Router

Type-safe Routing for React and Solid applications

Explore Router →
TanStack OSS
    Latest Posts
    TanStack Table V9: Taking FormJun 7, 2026TanStack AI: Your MCP, your wayJun 5, 2026TanStack Start Adds First-Class Rsbuild SupportJun 2, 2026