Martin Mwendajavascriptmasteryhub.hashnode.dev·Aug 19, 2024Understanding Javascript var, let and constUpon the release of ES2015 (ES6), two new ways of variable declaration were introduced to javascript. The two new keywords introduced were, let and const. Earlier the var keyword was only used to declared variables. In this article we dive deeper and...javascript hoisting
Bhavesh Jadhavbhaveshjadhav.hashnode.dev·May 28, 2024Understanding JavaScript Blocks and ScopeBlock in JavaScript A block, or compound statement, in JavaScript is defined by the curly braces {}. It is used to group multiple statements together. For example: { let a = 10; console.log(a); } Why Do We Need to Group Statements? We group ...11 likes·41 reads2Articles1Week
Bhavesh Jadhavbhaveshjadhav.hashnode.dev·May 27, 2024JavaScript Essentials: Understanding Scope, Lexical Environment, and HoistingUnveiling JavaScript Scope, Lexical Environment, and Hoisting: Demystifying Key Concepts Scope: Where Variables and Functions Live Scope determines where you can access a specific variable or function in your code. It is directly dependent on the lex...10 likesJavascript BasicsJavaScript
Zakeer Hussain SyedforFullstack Institutefullstackinstitute.hashnode.dev·Apr 23, 2024JavaScript Variables: Master var, let, & const for Cleaner CodeWhat are variables and why do we need them? Variables are like containers in your computer's memory that hold data. Imagine them as labeled boxes where you can store different items (numbers, text, etc.). They're essential for building dynamic progra...1 like·64 readsjavascript variables
Meghana S Kmeghanask.hashnode.dev·Apr 2, 2024Scope in JavascriptWhat exactly is the scope? Why do we need it? Scope determines the accessibility/usage of variables, functions and objects from different parts of the code. Before diving into its types, there is a term called lexical scope. Let's try to understand t...variable accessibility
Ojas Elawadhiojaselawadhi.hashnode.dev·Nov 17, 2023Hoisting in JavaScript: Demystifying the 'Lift and Shift'JavaScript, the language of the web, has its share of enchanting mysteries. One such mystery is "hoisting." Imagine it as a magical 'Lift and Shift' that happens behind the scenes. Let's unravel this wizardry in the world of JavaScript and make it as...JavaScript
Corina Murgcorina.hashnode.dev·Oct 27, 2023Demystifying Function Declarations Within Conditional BlocksIn the two previous posts in this series about hoisting, we talked about how function declarations - using the function keyword - are hoisted along with their definitions. This means we can call such a function BEFORE its code even appears, and it wi...Hoisting in JavaScriptfunction declaration
Nicole C.thepronicole.hashnode.dev·Sep 17, 2023The Scoop on Scopes JavaScriptOkay so you have declared your variable and you are ready to put it in use! You have an error. It's saying ReferenceError: (your variable) is not defined. That makes no sense you have declared it with a const. You're looking right at the variable. W...7 likesJavaScript
Anirudha Patilatomicjuggernaut.hashnode.dev·Apr 12, 2023JavaScript Interview Question: Function Scope vs. Block ScopeJavaScript, like any other programming language, has a concept of scope that dictates the lifetime or availability of a variable or function. In this article, we will explore the difference between function scope and block scope, hoisting in JavaScri...block scope
Kiprotich Dominickiprotichdominic.hashnode.dev·Mar 3, 2023Function Scope, Block Scope and Lexical ScopeFor the last 5 days, we have covered 5 topics in JS that are important for every developer to know. If you are new here you follow this link JS30IN30 to be able to read through the series. Scope Today we are going in-depth about the scope in Javascri...1 like·84 readsJavascript 30 Concepts In 30JavaScript