1

I've seen several times function like this

!function(self) {
    // code
}(this)

what means !function ?

user3260664
  • 145
  • 1
  • 3
  • 9
  • Here is a good explanation: http://stackoverflow.com/questions/3755606/what-does-the-exclamation-mark-do-before-the-function – EdwardB Aug 09 '14 at 10:54
  • 1
    It's a short-hand for self-invoking anonymous functions, it's same as `(function(){ // code })();` – Mritunjay Aug 09 '14 at 10:56

0 Answers0