Learning JavaScript. Code from JavaScript Good Part book.