The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

Thank you for your response. It doesn't really clear things up for me though. Perhaps I need a much better understanding of JS but what's the point of it? How does it apply to the whole function at hand? What purpose does it serve?
Good afternoon all and forgive me if this has already been asked, I did search the forums and couldn't find an answer to my question which is:

At the top of the javascript code in listing 1.5 (chap1) the first line is:

var spa = (function($)){

Being fairly new to javascript I don't understand what the passing of the '$' means into the function. If somebody would be good enough to give this novice a clue I'd very much appreciate it. I understand the rest of it just fine.