RE: TIL in JavaScript console.log you can do variable,variable

You are viewing a single comment's thread from:

TIL in JavaScript console.log you can do variable,variable

in javascript •  7 years ago 

yep! you should look into ES6 features as well! you can actually use variables via ${variableName}

Authors get paid when people like you upvote their post.
If you enjoyed what you read here, create your account today and start earning FREE STEEM!
Sort Order:  

Yes! I really like this:

var name = 'matthewdavid'
console.log('My name is ${name}.')

nice, will check it out thanks for the tip !