From React getting started tutorial:
React may batch multiple setState() calls into a single update for performance.
How do multiple calls to setState
can be batched to one call? Did they mean that multiple calls will be batched to multiple sync calls and one async call at the end?
I will love to see an example if it's possible.