TypeScript and JavaScript

TypeScript JavaScript A typed language that catches compilation errors early on You can find out errors during runtime Suitable for large projects as it improves code maintainability and readability As more code is added, becomes difficult to test and debug, thus JS is suitable for small projects Superset of JS, i.e., features like object-orientation, type-checking,… Continue reading TypeScript and JavaScript

Conditional Statements in JavaScript

“If condition A is true, let’s follow a set of instructions, otherwise, if it is false, let’s do something else.” Now, let’s consider a conditional statement that actually does something: var inNortherHemisphere = true; var latitude = 40.7; if (latitude > 30 && inNorthernHemisphere) { console.log(“It’s cold in December!”); } else { console.log(“It’s not cold… Continue reading Conditional Statements in JavaScript