Understanding JavaScript Hoisting
Hoisting is a concept that describes how JavaScript stores variable and function declarations in memory during the compilation phase.
Hoisting is a concept that describes how JavaScript stores variable and function declarations in memory during the compilation phase.
A closure is when an inner function can access variables from an outer function and remembers these variables.
Scope is the concept that determines where variables are accessible within your code, including global, function, and block scopes.
Read Full Article about JavaScript Scope and Scope Chain Explained
Due to binary representation and limited computer memory, 0.1 + 0.2 = 0.30000000000000004.
Read Full Article about Why Isn't 0.1 + 0.2 Exactly 0.3 in JavaScript?
Map/WeakMap are data structures similar to Objects, while Set/WeakSet are similar to arrays.
Read Full Article about Understanding Map, WeakMap, Set, and WeakSet in JavaScript
Map was introduced in ES6, while Object was traditionally used as a Map before ES6.
JavaScript has two main data types: primitives and objects. Primitives include String, Boolean, Number, BigInt, Undefined, Null, and Symbol; objects include Array, Function, and Objects.
null can be understood as nothing; undefined can be understood as not yet; undeclared refers to never having been declared.
Read Full Article about The Differences Between null, undefined, and undeclared in JavaScript
== performs type coercion and value comparison; === doesn't perform type coercion but compares values; Object.is() compares if two values are the same.
Read Full Article about Differences between ==, === and Object.is() in JavaScript
var, let, and const are reserved keywords used for variable declaration in JavaScript. Initially, only var was available until ES6 introduced let and const.
Read Full Article about Understanding var, let and const in JavaScript
In JavaScript, prototype is a crucial concept in object-oriented programming, serving as the key to implementing inheritance and property sharing.
In JavaScript, the value of 'this' is dynamic and typically determined by how a function is called. Therefore, what affects the value of 'this' is not when it's declared, but where it's invoked.
splice modifies the original array, allowing insertion, deletion, or both simultaneously; slice extracts a portion of an array or string, returning a new array or string without modifying the original; split divides a string into an array based on a specified separator, leaving the original string unchanged.
Read Full Article about Understanding splice, slice, and split in JavaScript