3

Searched for duplicates but couldn't find any..

Is there any substantial difference between:

var $foo = $(this);

and

var foo = $(this);

??

Toni Michel Caubet
  • 18,208
  • 50
  • 194
  • 356

1 Answers1

8

No difference. $ is a valid character in variables. It's a visual cue that tells you that's a jQuery object.

elclanrs
  • 89,567
  • 21
  • 132
  • 165