Tutorials 4
Traceur ES6 Template Feature
ES6 provides template string to render JavaScript expression.Template strings are string literals allowing embedded expressions. Template strings are enclosed by the back-tick ``. The expressions are included with dollar sign and curly braces as ${}. In this demo, “We will learn to use ES6 template string”. The following code contains a student detail object aStudent […]
Lodash Flow Function
Lodash provides flow function which helps in sequencing multiple functions in series. Lodash _.flow() method takes the function names as parameters and executes in sequence by binding to current scope. In this demo, “We will learn how to use lodash flow functions”. The following code shows 4 methods substractByOne(), addByTwo(),multiplyByThree() and divideByFour(). Lodash _.flow() method […]
Lodash Curried Function
Lodash supports the creation of curried function by using _.curry() method. A normal function when called with appropriate number of parameters it runs to the end of the execution. Sometime while programming we face situation when we don’t have sufficient number of parameters to call a function.I mean think of a situation when a method […]
Traceur ES6 Numeric Literal
ES6 provides support for Numeric literal like Binary,Octal and Hexadecimal number. The symbols for representing binary,octal and hexadecimal numbers are 0b,0x,0x respectively. In this demo,”We will learn about ES6 Numerical Literal”. The following code contains the Binary,Octal and Hexadecimal representation of decimal number 17. var aBinaryNumber = 0b10001; console.log("BINARY 0b10001 in DECIMAL: "+aBinaryNumber); var aOctalNumber […]