Books & Videos

Table of Contents

  1. Language

    1. Chapter 1 Values, Types, and Operators

      1. Values
      2. Numbers
      3. Strings
      4. Unary Operators
      5. Boolean Values
      6. Undefined Values
      7. Automatic Type Conversion
      8. Summary
    2. Chapter 2 Program Structure

      1. Expressions and Statements
      2. Variables
      3. Keywords and Reserved Words
      4. The Environment
      5. Functions
      6. The console.log Function
      7. Return Values
      8. Prompt and Confirm
      9. Control Flow
      10. Conditional Execution
      11. while and do Loops
      12. Indenting Code
      13. for Loops
      14. Breaking Out of a Loop
      15. Updating Variables Succinctly
      16. Dispatching on a Value with switch
      17. Capitalization
      18. Comments
      19. Summary
      20. Exercises
    3. Chapter 3 Functions

      1. Defining a Function
      2. Parameters and Scopes
      3. Nested Scopes
      4. Functions as Values
      5. Declaration Notation
      6. The Call Stack
      7. Optional Arguments
      8. Closure
      9. Recursion
      10. Growing Functions
      11. Functions and Side Effects
      12. Summary
      13. Exercises
    4. Chapter 4 Data Structures: Objects and Arrays

      1. The Weresquirrel
      2. Data Sets
      3. Properties
      4. Methods
      5. Objects
      6. Mutability
      7. The Lycanthrope’s Log
      8. Computing Correlation
      9. Objects as Maps
      10. The Final Analysis
      11. Further Arrayology
      12. Strings and Their Properties
      13. The arguments Object
      14. The Math Object
      15. The Global Object
      16. Summary
      17. Exercises
    5. Chapter 5 Higher-Order Functions

      1. Abstraction
      2. Abstracting Array Traversal
      3. Higher-Order Functions
      4. Passing Along Arguments
      5. JSON
      6. Filtering an Array
      7. Transforming with map
      8. Summarizing with reduce
      9. Composability
      10. The Cost
      11. Great-great-great-great-...
      12. Binding
      13. Summary
      14. Exercises
    6. Chapter 6 The Secret Life of Objects

      1. History
      2. Methods
      3. Prototypes
      4. Constructors
      5. Overriding Derived Properties
      6. Prototype Interference
      7. Prototype-less Objects
      8. Polymorphism
      9. Laying Out a Table
      10. Getters and Setters
      11. Inheritance
      12. The instanceof Operator
      13. Summary
      14. Exercises
    7. Chapter 7 Project: Electronic Life

      1. Definition
      2. Representing Space
      3. A Critter’s Programming Interface
      4. The World Object
      5. this and Its Scope
      6. Animating Life
      7. It Moves
      8. More Life-forms
      9. A More Lifelike Simulation
      10. Action Handlers
      11. Populating the New World
      12. Bringing the World to Life
      13. Exercises
    8. Chapter 8 Bugs and Error Handling

      1. Programmer Mistakes
      2. Strict Mode
      3. Testing
      4. Debugging
      5. Error Propagation
      6. Exceptions
      7. Cleaning Up After Exceptions
      8. Selective Catching
      9. Assertions
      10. Summary
      11. Exercises
    9. Chapter 9 Regular Expressions

      1. Creating a Regular Expression
      2. Testing for Matches
      3. Matching a Set of Characters
      4. Repeating Parts of a Pattern
      5. Grouping Subexpressions
      6. Matches and Groups
      7. The Date Type
      8. Word and String Boundaries
      9. Choice Patterns
      10. The Mechanics of Matching
      11. Backtracking
      12. The replace Method
      13. Greed
      14. Dynamically Creating RegExp Objects
      15. The search Method
      16. The lastIndex Property
      17. Parsing an INI File
      18. International Characters
      19. Summary
      20. Exercises
    10. Chapter 10 Modules

      1. Why Modules Help
      2. Using Functions as Namespaces
      3. Objects as Interfaces
      4. Detaching from the Global Scope
      5. Evaluating Data as Code
      6. The require Function
      7. Slow-Loading Modules
      8. Interface Design
      9. Summary
      10. Exercises
    11. Chapter 11 Project: A Programming Language

      1. Parsing
      2. The Evaluator
      3. Special Forms
      4. The Environment
      5. Functions
      6. Compilation
      7. Cheating
      8. Exercises
  2. Browser

    1. Chapter 12 Javascript and The Browser

      1. Networks and the Internet
      2. The Web
      3. HTML
      4. HTML and JavaScript
      5. In the Sandbox
      6. Compatibility and the Browser Wars
    2. Chapter 13 The Document Object Model

      1. Document Structure
      2. Trees
      3. The Standard
      4. Moving Through the Tree
      5. Finding Elements
      6. Changing the Document
      7. Creating Nodes
      8. Attributes
      9. Layout
      10. Styling
      11. Cascading Styles
      12. Query Selectors
      13. Positioning and Animating
      14. Summary
      15. Exercises
    3. Chapter 14 Handling Events

      1. Event Handlers
      2. Events and DOM Nodes
      3. Event Objects
      4. Propagation
      5. Default Actions
      6. Key Events
      7. Mouse Clicks
      8. Mouse Motion
      9. Scroll Events
      10. Focus Events
      11. Load Event
      12. Script Execution Timeline
      13. Setting Timers
      14. Debouncing
      15. Summary
      16. Exercises
    4. Chapter 15 Project: A Platform Game

      1. The Game
      2. The Technology
      3. Levels
      4. Reading a Level
      5. Actors
      6. Encapsulation as a Burden
      7. Drawing
      8. Motion and Collision
      9. Actors and Actions
      10. Tracking Keys
      11. Running the Game
      12. Exercises
    5. Chapter 16 Drawing on Canvas

      1. SVG
      2. The Canvas Element
      3. Filling and Stroking
      4. Paths
      5. Curves
      6. Drawing a Pie Chart
      7. Text
      8. Images
      9. Transformation
      10. Storing and Clearing Transformations
      11. Back to the Game
      12. Choosing a Graphics Interface
      13. Summary
      14. Exercises
    6. Chapter 17 HTTP

      1. The Protocol
      2. Browsers and HTTP
      3. XMLHttpRequest
      4. Sending a Request
      5. Asynchronous Requests
      6. Fetching XML Data
      7. HTTP Sandboxing
      8. Abstracting Requests
      9. Promises
      10. Appreciating HTTP
      11. Security and HTTPS
      12. Summary
      13. Exercises
    7. Chapter 18 Forms and Form Fields

      1. Fields
      2. Focus
      3. Disabled Fields
      4. The Form as a Whole
      5. Text Fields
      6. Checkboxes and Radio Buttons
      7. Select Fields
      8. File Fields
      9. Storing Data Client-Side
      10. Summary
      11. Exercises
    8. Chapter 19 Project: A Paint Program

      1. Implementation
      2. Building the DOM
      3. The Foundation
      4. Tool Selection
      5. Color and Brush Size
      6. Saving
      7. Loading Image Files
      8. Finishing Up
      9. Exercises
  3. Beyond

    1. Chapter 20 Node.js

      1. Background
      2. Asynchronicity
      3. The node Command
      4. Modules
      5. Installing with NPM
      6. The Filesystem Module
      7. The HTTP Module
      8. Streams
      9. A Simple File Server
      10. Error Handling
      11. Summary
      12. Exercises
    2. Chapter 21 Project: Skill-Sharing Website

      1. Design
      2. Long Polling
      3. HTTP Interface
      4. The Server
      5. The Client
      6. Exercises
    3. Chapter 22 Javascript and Performance

      1. Staged Compilation
      2. Graph Layout
      3. Defining a Graph
      4. A First Force-Directed Layout Function
      5. Profiling
      6. Function Inlining
      7. Going Back to Old-school Loops
      8. Avoiding Work
      9. Creating Less Garbage
      10. Garbage Collection
      11. Writing to Objects
      12. Dynamic Types
      13. Summary
      14. Exercises
  1. Appendix Exercise Hints

    1. Program Structure

    2. Functions

    3. Data Structures: Objects and Arrays

    4. Higher-Order Functions

    5. The Secret Life of Objects

    6. Project: Electronic Life

    7. Bugs and Error Handling

    8. Regular Expressions

    9. Modules

    10. Project: A Programming Language

    11. The Document Object Model

    12. Handling Events

    13. Project: A Platform Game

    14. Drawing on Canvas

    15. HTTP

    16. Forms and Form Fields

    17. Project: A Paint Program

    18. Node.js

    19. Project: Skill-Sharing Website

    20. JavaScript and Performance

  2. Updates