Inf Jhoanny
Inf Jhoanny

Reputation: 49

How can I concatenate two strings using template literals in typeScript?

How can I replace + with template literals in this case please?

.....
filters:[
{ divName: 'CSS'
  levels: [{key: 'GCSS', val:this.name + '(GCSS)'}]
}
],
...

Upvotes: 2

Views: 810

Answers (1)

Flo
Flo

Reputation: 3127

try this:

`${this.name}(GCSS)`

The backticks are important.

Greetings, Flo

Upvotes: 6

Related Questions