Use of $ in pure JavaScript - first lesson in 'What is JavaScript'
Scrabble96 opened this issue · comments
After struggling along for a couple of years copying code and getting help from StackOverflow etc I've decided it's time to learn plain JavaScript properly but without the use of any jQuery.
I thought $ was used for jQuery but in the first JavaScript lesson - 'What is JavaScript' - I've come across a $ sign in line 7 of the code, i.e: para.textContent = `Player 1: ${name}`;
There is no explanation as to why $ has been used. When I search $ and JavaScript the explanation seems to be that $ is treated the same as any a-z letter, but that's not the case in this code.
Actually, I've found an explanation at https://codedamn.com/news/javascript/dollar-sign-in-js