3 Differences: Eloquent Javascript 2nd Edition vs 3rd Edition

Before diving into the big differences between Eloquent Javascript 3rd edition and 2nd edition, you may wonder what is the same. If you read the 2nd edition, you will find that the structure, including chapters and sections, are nearly-identical, with whole swaths of conceptual paragraphs unchanged.

The order of chapters and the chapters titles are the same, with some minute differences. For example, the 2nd edition has two separate chapters for HTTP and forms, whereas in Eloquent Javascript 3rd edition, the two chapters are combined. For this article, I do not intend to focus on the small differences, but the bigger, high-impact ones.

Difference 1: Eloquent Javascript 2nd Edition Does Not Cover ES6

In the introduction of both Eloquent Javascript 3rd edition and 2nd edition, you find a detailed history of Javascript. Because the 2nd edition of Javascript was released in 2014, that pre-dates the release of Javascript’s major update, ECMAScript 2015 or ES6.

The introduction of Eloquent Javascript 2nd edition says:

Changing a living, widely used language in such a radical way turned out to be politically difficult, and work on the version 4 was abandoned in 2008, leading to the much less ambitious version 5 coming out in 2009. We’re now at the point where all major browsers support version 5, which is the language version that this book will be focusing on. A version 6 is in the process of being finalized, and some browsers are starting to support new features from this version.

But the introduction of Eloquent Javascript 3rd edition says:

Changing a living, widely used language in such a radical way turned out to be politically difficult, and work on the version 4 was abandoned in 2008, leading to a much less ambitious version 5, which made only some uncontroversial improvements, coming out in 2009. Then in 2015 version 6 came out, a major update that included some of the ideas planned for version 4. Since then we’ve had new, small updates every year. The fact that the language is evolving means that browsers have to constantly keep up, and if you’re using an older browser, it may not support every feature. The language designers are careful to not make any changes that could break existing programs, so new browsers can still run old programs. In this book, I’m using the 2017 version of JavaScript.

In these contrasting quotes, I intentionally left some overlap to show that some of the language has not changed from one book to the other. If you are a fan of the original, you will find much has not changed. For example, the introductions between versions are nearly identical, with the same sections: “On Programming,” “Why Language Matters,” and so on. The illustration has changed, as has the opening paragraphs.

Though the editions have many similarities, it is worth investing in Eloquent Javascript 3rd edition for one big reason: we need to know ES6 features as modern Javascript developers. The industry, and the browsers themselves, demand this change. Though the book structure is the same, reading the book in the context of 2017 ECMAscript is worth the time investment of reading a newer edition.

And if you are concerned about it being ECMAscript 2017, which is soon-to-be 3 years old, feel safe knowing that the major update was in 2015. ECMAscript releases annually, making catch-up easy. Once you understand the major features, you can look up release notes or articles to brush up on the new features.

Difference 2: Eloquent Javascript 3rd Edition is Better Written

What do I mean by better written?

The 3rd edition book cuts needless words and simplifies language. The writing is tighter and with a sharper eye toward technical writing. In my free email course on Getting the Most From Technical Books, I advice to “read only good technical books,” but “good” can often be hard to define.

Good technical writing removes all ambiguity. Good technical writing is simple and easy to understand. Good technical writing does everything it can to remove barriers to understanding. That means good technical writing digests the materials and presents them well. It never makes you feel stupid, which I also talk about in How to Read Programming Books.

Eloquent Javascript 3rd edition has better technical writing than in the 2nd edition.

For example, the book is more conscientious about conceptual information by putting definitions in italics and defining terms immediately and in simple terms.

The 3rd edition also uses shorter sentences and few complex sentences, which improves readability.

To see this for yourself, observe the first paragraph of Eloquent Javascript 2nd edition:

This is a book about getting computers to do what you want them to do. Computers are about as common as screwdrivers today, but they contain a lot more hidden complexity and thus are harder to operate and understand. To many, they remain alien, slightly threatening things.

And the first paragraph of Eloquent Javascript 3rd edition:

This is a book about instructing computers. Computers are about as common as screwdrivers today, but they are quite a bit more complex, and making them do what you want them to do isn’t always easy.

You can see that the paragraphs are the same, but revised.

Here are a handful of choices made in this first paragraph:

Instead of the wordy “getting computers to do what you want them to do,” it is simply “instructing computers.” Brilliant.

The 2nd edition uses the trite word “thus,” which is removed.

Bigger phrases like “hidden complexity” is swapped for “are quite a bit more complex.” This is easier to conceptualize, as “hidden complexity” is a loaded phrase.

The 2nd edition uses the phrase “they remain alien,” which is removed in the 3rd edition. The word “alien” has many dictionary definitions, which can be hard on non-native English speakers. The choice to remove that phrase is smart.

The first paragraph is perhaps the most important cluster of words in a book. In the first paragraph alone, the many tiny choices are smart, which sets the scene for the rest.

Difference 3: Eloquent Javascript 3rd Edition Has a New Project

In Eloquent Javascript 3rd editions, one of the projects from the 2nd edition was scrapped (“Electronic Life“) and replaced with a new project called “A Robot.”

You may be thinking that “Electronic Life” sounds like a synonym for “A Robot,” but trust me — the projects are different. This new one is about graphs and Dijkstra’s algorithm, whereas the 2nd edition exercised focused on a two-by-two grid.

Also, this new project is more advanced and more challenging.

Here is the description of the “A Robot’ project in Eloquent Javascript 3rd edition:

Our project in this chapter is to build an automaton, a little program that performs a task in a virtual world. Our automaton will be a mail-delivery robot picking up and dropping off parcels.

And here is the description of the “Electronic Life” project in Eloquent Javascript 2nd edition:

Our project in this chapter is to build a virtual ecosystem, a little world populated with critters that move around and struggle for survival.

The project description of the 2nd edition may sound familiar to you. Having taken a number of programming classes, I have done the “Electronic Life” project twice already, which I know as the “Game of Life.”

But I have not heard of the mail-delivery robot project. Immediately, I am more intrigued. This is not an out-of-the-box computer science course assignment.