🧱JavaScript uses a stack and heap to manage memory
📚Stack stores local variables and is compared by value
🗄️Heap stores arrays and objects and is compared by reference
⛓️React uses object.is to compare dependencies in useEffect
🔄Understanding memory management is crucial for avoiding mistakes in JavaScript