Var vs. Let in JavaScript

In this article, we wil be discussing the long running debate of var vs. let in JavaScript. We will also be discussing why the use of let is increasing in dev communities.

Var vs Let in JavaScript

Introduction

Declaring variables in JavaScript was not a cake walk until 2015 when ECMA 2015 was introduced and hence let and const was introduced and we got rid of var (it still works though!).

JavaScript Objects in Depth, Part 1: The Fundamentals

Introduction

JavaScript has two main data types: primitives and objects. The interesting thing here is that other than the primitive type everything else is an object, including functions. Therefore, if we are really interested in learning JavaScript, then understanding objects should be on the top in the list.

An object can be created with figure brackets ( {...})with an optional list of properties where a property is a key:value pair, where the key is a string and the value can be anything. By anything, we mean it can be a primitive or an object or even a function.

An Introduction to JavaScript/ES6 Arrow Functions

Arrow Functions help programmers to write declarative code with JavaScript. While everyone may have different feelings about this addition to Javascript/ES6, whatever camp you belong to you, you will have to deal with variations of Arrow Functions.

Why Do You Need to Know This?

Theoretically, you don't need to learn to use arrow functions at all. You can do everything with good old "function" that you have been doing since you started writing JavaScript code. It could be advantageous in some cases, but you can get away without using them. But even if you don't use it right now, you might end up using arrow functions in the future or you might have to maintain code that was written by someone who loved using arrow functions.