Skip to main content

References in the Learning TypeScript Book

· 20 min read

Finding the right names and values for small code snippets is a surprisingly challenging task. Sample content like foo bar and lorem ipsum gets boring quickly -- and can be confusing to readers who aren't yet familiar with them. It's better to have self-contained code snippets that can be clearly understood without any external context.

Crafting appropriate themed content that fits cleanly with the theory being demonstrated is fraught with danger. Code snippets shouldn't contain an egregious quantity of tangentially-related setup code just to justify their theme. Themes also shouldn't be unnecessarily flashy to the point of distracting from the important conceptual explanations.

Many authors opt to stick with a small set of themes they know to be flexible and work well. I personally go with names of fruit, such as counting amounts of them. While sticking with the same theme repeatedly is reliable, it can get boring for the reader fast.

That's why, at risk of distracting ever so slightly from code content, most chapters in Learning TypeScript use an overarching theme for most or all of its code snippets. Most of the themes are fairly straightforward, such as historical authors or inventors. Others are a little more subtle and act more like easter eggs.

Criteria for Inclusion

I also paid special attention to the gender and race makeup for people referenced in the book. Most software textbooks are significantly skewed towards white men in their quotes. Some don't include a single quote from any group underrepresented in tech! Learning TypeScript inverses that ratio: the vast majority of its references are to people who belong to groups underrepresented in the tech industry.

Most referenced people are not young (below retirement age). I worry that someone who seems great at time of publishing may turn out to be a negative figure later on (see: Elizabeth Holmes; J. K. Rowling). Still, there are a few pre-retirement figures in whom I have high confidence and I couldn't resist including.

I also included a few small jokes or references to games, movies, and other media. Those are not mentioned here. Consider them easter eggs for you to discover as you carefully scrutinize the book. 😉

Including hidden easter eggs, there are about 150 references in the book.

All References

In order of their first book appearance..

Chapter 1: From JavaScript to TypeScript

Theme: Artists

Chapter 2: The Type System

Theme: Singers

Chapter 3: Unions and Literals

Theme: Scientists and Researchers

Chapter 4: Objects

Theme: Poets

Chapter 5: Functions

Theme: Singers and Songs

Chapter 6: Arrays

Theme: Soldiers

Chapter 7: Interfaces

Theme: Authors and Books

Chapter 8: Classes

Theme: Teachers

Chapter 9: Type Modifiers

Theme: Comedians and Comedies

Chapter 10: Generics

Theme: Assorted 🤷‍♂️

Chapter 11: Declaration Files

Theme: Comedies and Comedic Characters

Chapter 12: Using IDE Features

Theme: Science Fiction

Chapter 13: Configuration Options

Theme: Activists

Chapter 14: Syntax Extensions

Theme: Activists, continued

Chapter 15: Type Operations

Theme: Conservationists