VVVishnu V Nairinvishnuvnair.hashnode.dev·Dec 25, 2022 · 5 min readShort Circuiting in JavaScriptIntroduction Consider the following code snippet: // if-else statement if (isUserLoggedIn) { return privateData; } else { return false; } The above code can be written in a more concise way like this: // Short Circuiting isUserLoggedIn && pr...00
VVVishnu V Nairinvishnuvnair.hashnode.dev·Aug 31, 2021 · 3 min readType Conversion and Type Coercion in JavaScript : An IntroductionType Conversion: We manually convert one data type to another. Type Coercion: JavaScript automatically converts data types behind the scenes for us. Type Conversion Type Conversion is said to happen when the programmer explicitly transfers data from...00
VVVishnu V Nairinvishnuvnair.hashnode.dev·Aug 31, 2021 · 3 min readlet, const and var in JavaScriptThere are three different ways of declaring a variable in JavaScript : let const var let and const were introduced in ES6, while var is the older way of declaring variables in JavaScript. let We use the let keyword for variables whose value we i...00