- In addition to Var, Let and Const What else is used in jQuery?
- In what cases is $?
Answer 1, Authority 100%
var is not desirable to use in new projects. Or with the full understanding of their features compared to
In addition to Var, Let and Const What else is used in jQuery?
jQuery is a library that uses native js , so the rules are exactly the same as even JS
In what cases is $?
My recommendation (and we are doing in the company in projects): All variables related to the object jQuery called that they start with
$ . This will give an understanding to other people that, for example, in a variable
$ Users – object jQuery with users, and not js Collection of objects.