As you learned in the previous chapter, almost everything in JavaScript is an object, including functions. However, functions are much more than just bags for containing properties; they are how work gets done in the language. Typically, developers become aware of the specifics of functions only when something they wrote explodes in their face. My goal in this chapter is to expose the intricacies of JavaScript functions to you, which will hopefully save you from having to pull syntactic shrapnel from your codebase.

A word of caution before I begin: JavaScript is only as good as its interpreter. Although the concepts discussed ...

Get Expert JavaScript now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.