Errors in JavaScriptErrors are objects in js, which are thrown when runtime error occurs. The error can also be a base object for user defined exceptions. Runtime errors result in new Error, objects being created and thrown. Serializable object A seriziable objects is o...Apr 8, 2025·3 min read
Function Declaration vs Function ExpressionThere is a good difference between these 2 ways of calling a function 1) The hoisted function can be called for anywhere in the code, it sits on top of the stack JS engine will make sure they are executed first and so can be refered anywhere 2) The ...Feb 26, 2025·3 min read
Deep Copy vs Shallow CopyShallow Copy: A shallow copy creates a new object, but the properties of that object still refer to the same memory locations as the original object's properties. This is what happened in your array example Deep Copy: A deep copy creates a new obje...Feb 10, 2025·1 min read
Objects in JSLet’s talk about how objects in js so we have an clear understanding of what are we doing Stack vs Heap In JS there are 2 ways of storing the memory, primitive data-types are stored in a stack form. while non-primitive data-types (arrays, objects) ar...Feb 10, 2025·3 min read