ES6 Tutorials for beginners in Hindi
ES6 (or ECMAScript 6) is new standard of JS . This course covers - let, const, arrow functions, destructuring, rest params, higher order functions. We also have included some later versions also like ES7. This course is recommended after our JS course.
#1 LET and CONST
VAR has lots of issues in javascript related to scope of variable. It lead to lot of programming mistakes in past, as common as duplicate variable declaration and overwriting of values un-intentionally. However new keywords LET and CONST help us a lot to avoid such programming disaster.
#2 Arrow Functions
Arrow functions are new style of writing functions which are intended to just return a value. Also arrow functions don't create a new function scope. This makes writing these much easier in case of a callback function.
#3 Template Literals
Template literal or String literals are way to declare variable inside a text. This is much easier than old style of concatenation of strings. You can write a long text and embed as many variables as you like without issues of formatting.
#4 Default Parameters
Default params are way by which a function can take default value of argument. It is specially useful in making program efficient, where some common value is already passed in like value of PI, e or some some global constants.
#5 Spread Operators
Spread operators are a way to spread properties of an object without a loop. By doing this you can make a collection of all properties and use them to initialise new objects. Also it provides easier way to copy without leaving a reference or deep copy.
#6 Rest Parameters
Rest params are ways to make number of argument as variable. Hence you can pass as many variables as you like in a functions. The arguments will be collected like an array automatically. This help us to make more generalised functions for N number of arguments. Like Sum of N number, Average of N numbers etc.
Next Up : ReactJS Tutorials for Beginners in Hindi