DevExtreme v24.2 is now available.

Explore our newest features/capabilities and share your thoughts with us.

Your search did not match any results.

React Toast - Stack

The DevExtreme Toast components can stack multiple notifications. Use the notify(message, stack) or notify(options, stack) method to display stacked messages.

These methods use a stack object that has the following structure: {position, direction}.

To give you the ability to edit code on the fly, the demo uses SystemJS. For this reason, launching the demo takes some time. We strongly recommend that you do not use this approach in real projects.
Backend API

Specify Position

You can set the position field to a string (select 'predefined' in the radio group) or an object (select 'coordinates' in the radio group). Note that if you use coordinates for the position field, you need to specify one vertical and one horizontal coordinate only. For example, if you specify 'top', the demo disables the 'bottom' field, and vice versa.

Specify Direction

The direction field specifies two options: which way the notification stack grows and whether new notifications appear at the end or at the beginning of the line. For this reason, the field's pull-down menu choices show pairs of values such as 'up-push' and 'up-stack'.

  • 'up-push'
    New toasts push the previous toasts upwards.

  • 'up-stack'
    Toasts stack on top of each other.

Hide Toasts

To hide all toast messages, use the hideToasts method.