user3536460
user3536460

Reputation: 75

I don't get meaning of $ symbol in this context

Here's snippet which I been reference in book:

`photos/${Date.now()}.jpg`

I got curly brackets used to 'out of string', however mean of $ ...

ps: sincerely I also not want to ask question but I not know what I looking for

Upvotes: 0

Views: 54

Answers (1)

Hien Nguyen
Hien Nguyen

Reputation: 18975

It is interpolation (template literals)

It will equal to "photos" + Date.now() + ".jpg"

Upvotes: 2

Related Questions