Skip to content

Example 3: Counters

Showcasing local and global state: The local state of the counter components doesn't change when moved inside one grid, but is cleared when moved to another. The global state is in the data attribute of each item and gets transferred as well. Both grids also have custom highlights.

This is a custom highlight!

External counter:

1

Internal counter:

0

External counter:

4

Internal counter:

0

External counter:

-1

Internal counter:

0
← Drag here please →
This is a custom highlight!

External counter:

30

Internal counter:

0

External counter:

3

Internal counter:

0

Released under the Apache-2.0 License.