Learn Enough JavaScript to Be Dangerous

Author: Michael Hartl
Publisher: Addison-Wesley
Date: June 2022
Pages: 304
ISBN: 978-0137843749
Print: 0137843747
Kindle: B09RDSVV7N
Audience: Would-be JavaScript developers
Rating: 2
Reviewer: Mike James
To be dangerous? Is this a good ambition?

I'm not in sympathy with the title of this book. It's not what you might think however. I really do approve of the "to be dangerous" part of the title. It is the "Enough" I have a problem with. What sort of aspiration is it to just learn "enough" and to be really dangerous you need to learn a lot more than "enough". Or is the title supposed to be taken as "enough to be incompetent and hence blow your own foot off".

Never mind the sentiment, we can write it off as a publicity angle trying to make a distinction between this book and all the other JavaScript books out there. It's meaning may be dubious, but it made me stop and read it - shame on me perhaps...

So was I happier when I got beyond the title? 

Not really.

Banner

At the start of Chapter 1 we are told:

"There are no programming prequisites for Learn Enough JavaScript to be Dangerous..."

Well this is only slightly true and very misleading. The first thing is that the book uses Linux and you are expected to be happy with the Linux command line. This might be a tall order for a beginner, although the author does point you to a  online tutorial in his "Learn Enough" series of online books and streaming video.

The book does include a "Hello World" example, but on page 7 we have

git init
git add -A
git commit -m "initialize repository"

Yes, before "Hello World" we have to use Git!!! I'm prepared to admit that many a modern programmer would be lost without Git or similar but making it something that has to be tackled before any programs have been written seems hard. Again GIT is covered in one of Hartl's ten Learn Enough online courses. 

Next rather than run the JavaScript program locally, the program is added to the repository and then GitHub pages. Repeatedly the message that you probably should have read the Learn Enough Git, HTML and CSS material before this one is made very clear. If the reader hasn't read the online books by the same author then this particular book isn't going to take you very far.

You may not have to have any programming knowledge before starting in on this book but you definitely need a lot of knowledge and competence in other largely unconnected things.

From here we move on to a chapter on strings and by the way we look at the flow of control. The chapter is heavy on detail and light on general principles. The approach is light-hearted and there are lots of photos with cute captions but they don't really add anything. If you can't understand the text, the extras don't help - they probably won't even make you smile.

 

After looking at strings we move on to arrays and then other native objects. Notice that the idea of an object hasn't really been made central to anything, but it is used repeatedly. In the chapter on other native objects we have regular expressions, which could very much wait till the reader has mastered some more fundamental ideas. This is not a gradual introduction to JavaScript.

Next we get to functions, the most important detail of which is that they are objects but this fact is ignored. Instead we have method chaining which is far from fundamental. Then on to functional programming - well we have just been introduced to functions, so why not. This isn't really about functional programming - it's about using map, filter and reduce and TDD (test driven development) although what that has to do with functional programming I'm not sure. 

Eventually we have reached objects. but they are covered in a brief and shallow few pages just before the book ends with a look at TTD and event handling, DOM manipulation, shell scripts and a big example.

Conclusion

This is a book that isn't for the beginner, unless that beginner is happy with a lot of technical things beyond JavaScript. If they are then my guess is that the presentation is going to be too slow, too slight and too incomplete. This book is overall heavy on detail and light on principles and ideas. You might be its ideal reader, but I doubt it will make you in the slightest bit dangerous.

For recommendations of JavaScript books suitable for beginners see JavaScript Beginners Book Choice in our Programmer's Bookshelf section.

To keep up with our coverage of books for programmers, follow @bookwatchiprog on Twitter or subscribe to I Programmer's Books RSS feed for each day's new addition to Book Watch and for new reviews.

Banner


PostgresSQL 14 Administration Cookbook

Author: Simon Riggs and Gianno Ciolli
Publisher: Packt Publishing
Pages: 608
ISBN: 978-1803248974
Print:1803248971
Kindle: B09R4VBHX3
Audience: PostgresSQL developers and administrators
Rating: 4.5
Reviewer: Kay Ewbank

While this book describes itself as a cookbook, the recipes in it work through the nec [ ... ]



Data Structures & Algorithms in Python

Author: Dr. John Canning, Alan Broder and Robert Lafore
Publisher: Addison-Wesley
Date: October 2022
Pages: 928
ISBN:978-0134855684
Print: 013485568X
Kindle: B0B1WJF1K9
Audience: Python developers
Rating: 4
Reviewer: Mike James
Data structures in Python - a good idea!


More Reviews

Last Updated ( Wednesday, 03 May 2023 )