Does it have any use cases in native Javascript, Jquery, or Angular? I found out about this notation when I was reading about the use of $ in front of variable names. The $ is used a lot in Jquery, does it have any relation to Hungarian Notation also?
Asked
Active
Viewed 2,486 times
-6
-
6Were you unable to use google when you wrote this question? – zzzzBov Apr 27 '16 at 17:10
-
6have you tried any simple internet searching? – Pointy Apr 27 '16 at 17:10
-
2In a way, yes. It's an indicator that the variable contains a jQuery object. – Felix Kling Apr 27 '16 at 17:14
1 Answers
2
What is Hungarian Notation?
The StackOverflow tag itself says: "Hungarian notation is a language-independent naming convention in which an identifier's prefix indicates its type. Examples include iCustomerId, sFirstName, etc."
Does it have any use cases in native Javascript, Jquery, or Angular?
It can have, if you want it to.
The $ is used a lot in Jquery, does it have any relation to Hungarian Notation also?
As Felix King said: "In a way, yes. It's an indicator that the variable contains a jQuery object."
Again, more thorough answers to all those questions are available on the internet, it's not a SO question.