Posts

Showing posts with the label how to use template strings in javascript

Template strings in javascript (understanding ES6)

Image
 Template strings in javascript (understanding ES6) Template strings are basically the latest way of concatenating strings or be it functions and has come alive with the ES6 version of ecmaScript. So let us understand how we use Template String to concatenate or join two given strings before ES6 and once it has come: < script >      var  FirstName =  "Praveen" ;      var  MiddleName =  "Kumar" ;      var  LastName =  "Yadav" ;     document.write( ` ${ FirstName }   ${ MiddleName }   ${ LastName } ` );     console.log( ` ${ FirstName }            ${ MiddleName }              ${ LastName } ` );         // OLD WAY OF CONCATINATION OF STRINGS    ...