Ramatou Adamou Issa

Ramatou Adamou Issa

  • Experiences
  • Formation
  • Musics
  • Blog

›Recent Posts

Recent Posts

  • Watchtower, container for updating docker images
  • PHP8 (Migrating existing PHP7 project to PHP8)
  • What news in Symfony 5
  • Command Query Segregation Responsibility (CQRS)
  • AFUP conference feedbacks

ES6 - Templates Literals - Object Literals - Classes

May 7, 2019

Nicolás Bevacqua

Template Literal (string interpolation)

String declaration


    `example with a ${variable}`

Interpolation with valid Js expression


    `${variable * 3} is the result`      

Interpolation with tagged templates


    fn`test, ${$test} and ${test2} `      

See more examples here

Object Literal

Property value shorthand

    {foo : foo} or just {foo}     

Compute property name

    {[prefix + 'End']: 'test prefix'} 
    
    //prefix = 'pref',  result will be {prefEnd: 'test prefix'}      

See more examples here

Tweet
Recent Posts
  • Template Literal (string interpolation)
  • Object Literal
Ramatou Adamou Issa
Ramatou Adamou Issa
HomeExperiencesFormation
Social Networks
InstagramTwitterChat
Accounts
Gallery photoBlogGitHubStar
Copyright © 2025 Ramazaki