Sonner Promise 2 - Promise toast with data

Pro

Promise toast that interpolates resolved data into the sonner success message.

Shadcn Sonner Promise 2 component

Component Data

  • ID:sonner/sonner-promise-2
  • Access:pro
  • Created:Oct 5, 2025
  • Type:example

Sonner Promise 2 component design & features

This sonner example uses the shadcn Sonner component with toast.promise and a success callback that reads the resolved value. The success copy includes data from the promise, such as a created user name.

Use this sonner component when the confirmation should name the record that was created, updated, or imported.