Checkout this video:
var message = “This is a variable.”;
var $ = “This is also a variable.”;
For example, if you have an object called myObj with a property called name, you can access the name property like this:
myObj.name // returns “John”
You can also access the property using the dollar sign:
myObj.$name // also returns “John”
The dollar sign is just a shorthand way of accessing properties. It can be used with any object, not just DOM elements.