Stop Freezing Your UI 🍿
Imagine you go to a restaurant 👩🍳 and a server comes to take your order but until your food is ready, you're frozen and not allowed to chat with your friends, drink water or do anything.
That's the reality in your browser 😅.
If you press a button, your entire UI freezes and unless you fix this, you won't be able to do anything.
That's where useTransition come in play.
Without useTransition, when you click a button that does something expensive, your entire app becomes unresponsive.
📜 Can't scroll - You're stuck looking at the same part of the page
▶️ Can't click other buttons - Everything is frozen
🧭 Can't navigate - You're trapped until the operation completes
useTransition is like having a waiter who takes your order and then works in the kitchen while you can still chat with friends, drink water, and move around.