by Callie L. French, Dan/M Pelletier
ISBN: 0764363778
Buy on Amazon
Found in 27 comments on Hacker News
solidist · 2020-07-01 · Original thread
JavaScript: The Good Parts by Douglas Crockford. Note that this was written in 2008 but still holds up well.

https://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfo...

It may be a perfect time for a revision.

no_wizard · 2020-06-16 · Original thread
I also want to add the great Eloquent JavaScript[0] to this list. While its targeted at learning programming as a whole, its still a wonderful resource, even for seasoned programmers, to learn some ins and outs of the language if you haven't had a lot of experience with it.

I also want to give mention to JavaScript: The Good Parts by Douglas Crockford[1], and his new book, How JavaScript Workers[2]

[0]: https://eloquentjavascript.net/

[1]: https://www.amazon.com/dp/0596517742/wrrrldwideweb

[2]: https://howjavascriptworks.com/

gwbas1c · 2020-02-19 · Original thread
Something to keep in mind: Javascript has a lot of obscure language idiom that aren't used in practice. This has to do with how the language was rushed into production, and has gone through quite a lot of revisions.

This point is made in the (now very outdated) book "Javascript: The Good Parts," https://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfo.... Crockford, the author, brings you through the best way to write Javascript in 2008.

Related note: I once attended a talk from Crockford in 2010 where he was rather religious about how async code was significantly better than threads. I pointed out that async code is significantly harder to write due to the mess of callbacks, and his answer was quite rude. Now Javascript has async-await, which fixes the madness that comes from callbacks.

dlojudice · 2019-09-26 · Original thread
JS is going to be so different in 2019 that I'm expecting a revised version of "The Good Parts"[1]

[1] https://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfo...

Read this https://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfo...

That's really all you need to get started.

MollyR · 2015-10-23 · Original thread
davidw · 2015-04-30 · Original thread
JavaScript is kind of ugly in some ways, but not really complicated. You could easily pick up the basics in that time frame.

I've heard people say good things about this book:

http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

But I've never read it myself.

Shizka · 2014-11-18 · Original thread
I've had the exact same concerns as the person you replied to. I just want to make sure since the title differs from the one you stated. Is this the book you were talking about: http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor... And how/why did the book improve your opinion about the language?
krapp · 2014-10-05 · Original thread
You may have to learn to put up with it. It's not the end of the world. It's just a scripting language, just suck it up and deal.

There are any number of js frameworks which will probably abstract away most of the headaches you might have, and depending on what you're actually trying to accomplish, you may not need a lot of js at all. If you don't want to use client-side templating, for instance, and there's no reason to, then just skip it. Push as much of it to the backend in the language of your choice as you can.

But javascript, when you need scripting in the browser, is kind of unavoidable.

Also consider http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor... - your expectations from working with other languages may be getting in the way of your writing javascript properly and effectively.

(or do what a lot of other people do and work with a language that compiles to js and you can pretend you live in an alternate universe where you're not working with javascript even though you really are.)

klaaspieter · 2014-07-03 · Original thread
Yes. I believe such a book exists (or should at least) for every language as well.

Effective Java — http://www.amazon.com/Effective-Java-Edition-Joshua-Bloch/dp...

POODR (Ruby) — http://www.poodr.com/

Javascript the good parts — http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

There is of course also the gang of 4 language agnostic classic on design patterns http://www.amazon.com/Design-Patterns-Elements-Reusable-Obje...

doorhammer · 2014-03-04 · Original thread
Code Complete 2 [1] was one of the first coding books I've read. As with anything else, it's good to look around (HN is a good place) for people who have problems with the book. I think I learn as much reading the commentary people make about books like that as I do from the book itself.

I think I've listened to every podcast on software engineering radio a few times [2]. The older ones are especially nice because they usually pick a specific topic and cover the high points. I liked that I could listen to it while I was driving, or otherwise not in front of a computer.

It's specific, but Javascript: The Good Parts is probably the most used book I have on my shelf. It has such a perfect amount of usable information in it. It's pretty great. Again, it's definitely worth looking up critiques and counterpoints.

I've also got Introduction to Algorithms, which I use as a reference, sometimes. I switched over to The Algorithm Design Manual [5] after I saw it referenced in an older Steve Yegge post [6]. I read through the intro and it seemed like a book that would be more appropriate from an autodidactic standpoint. I really have no idea if that's going to pan out, since I'm not that far into it, but we'll see, for sure. Doesn't kill me to have an extra algorithms book laying about, though, and I've always got intro to algorithms for cross reference. I've found that I really need to have as many sources available as possible when I'm learning alone. Usually I don't get something until the fifth person describes it from the tenth different angle.

That's most of what I can think of off hand. I really enjoyed The Joy of Clojure [7], though haven't checked out the newer version. Programming Collective Intelligence [8] is a fun book, and is what made me want to go back down the maths route to get more into machine learning.

And of course habitually reading hacker news for an hour or three every night :)

So that's my totally inexpert list of random stuff that I enjoy

[1] http://www.amazon.com/Code-Complete-Practical-Handbook-Const... [2] http://www.se-radio.net/ [3] http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor... [4] http://www.amazon.com/Introduction-Algorithms-Thomas-H-Corme... [5] http://www.amazon.com/Algorithm-Design-Manual-Steven-Skiena/... [6] http://steve-yegge.blogspot.com/2008/03/get-that-job-at-goog... [7] http://www.amazon.com/Joy-Clojure-Michael-Fogus/dp/161729141... [8] http://www.amazon.com/Programming-Collective-Intelligence-Bu...

auslegung · 2014-02-26 · Original thread
In addition to what Isiebert said, if you're a book person, read javascript, the good parts http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor....
shadowcats · 2014-02-06 · Original thread
I would of course add "The good parts" by Crockford to the list.

But maybe that is just par for the language course, before one even starts to wants to master Engineering :)

JavaScript: The Good Parts - http://www.amazon.com/gp/product/0596517742/ref=as_li_ss_tl?...

Here's a few other good ones:

Functional JavaScript: Introducing Functional Programming with Underscore.js - http://www.amazon.com/gp/product/1449360726/ref=as_li_ss_tl?...

Secrets of the JavaScript Ninja - http://www.amazon.com/gp/product/193398869X/ref=as_li_ss_tl?...

Javascript Allongé (free to read online) - https://leanpub.com/javascript-allonge

Javascript Spessore (free to read online, but currently work in progress) - https://leanpub.com/javascript-spessore

Here's a good one about Angular, my favorite framework:

Mastering Web Application Development with AngularJS - http://www.amazon.com/gp/product/1782161821/ref=as_li_ss_tl?...

I would of course also recommend the Egghead videos for any Angular aficionados: http://www.youtube.com/playlist?list=PLP6DbQBkn9ymGQh2qpk9Im...

PS. The Amazon links are affiliate links.

user_235711 · 2014-01-24 · Original thread
I second JavaScript: The Good Parts[1]. It is very well-written and very dense, so you can read and reread it multiple times, each time gathering something new. Along with that I would recommend the Mozilla Developer Network JavaScript reference[2].

[1] http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

[2] https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe...

auslegung · 2013-11-02 · Original thread
Javascript: the good parts <http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor....

Eloquent Javascript <http://eloquentjavascript.net>.

These two are a great start.

pjungwir · 2013-07-28 · Original thread
If you're just getting started with Javascript, I'd say learn Javascript and jQuery. Here are two good books:

    http://www.amazon.com/dp/0596517742     http://www.amazon.com/jQuery-Action-Second-Bear-Bibeault/dp/1935182323 
If you want to use Javascript/Ajax in a Rails application, this is a good introduction to how Rails' "remote" forms/links work in a jQuery context:

    http://www.alfajango.com/blog/rails-3-remote-links-and-forms/     http://www.alfajango.com/blog/rails-3-remote-links-and-forms-data-type-with-jquery/ 
I would get to the point where you understand all that before tackling Angular, Ember, or Node.

cpleppert · 2012-12-31 · Original thread
I haven't found a use for a lot of these features, a lot of them just seem very ad-hoc additions to the language. A class based object oriented model would have solved a lot of issues relating to the myriad ways to implement object orientation in javascript. The schizophrenic like approach we have right now isn't being helped by incremental changes driven by the lowest common denominator of what can be implemented in a web browser development cycle.

Knowing the [Good Parts](http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...) helps but you just can't keep adding parts that you think may be good.

sanderjd · 2012-11-24 · Original thread
While I think GWT is a pretty good project and has some way to go before it can be categorized as failing, some of your other remarks make me think that you have not given appropriate consideration to the alternatives to its approach.

First and foremost, you can write javascript in such a way that your code does nothing weird and only what you intended. A good place to start is still "JavaScript: The Good Parts"[1]. Then I suggest finding some examples of nicely written javascript code on GitHub or some such site. I personally think underscore.js[2] and backbone.js[3] are rather nice.

If you have really given javascript a fair shot, and still strongly dislike it, there are many other languages that compile into javascript, but match its style more closely that Java does. I have been enjoying working in CoffeScript[4]. There is an excellent interactive book[5] that shows the javascript generated by the constructs in the language, which is also a good resource for discovering idioms to do things that are not obvious in javascript, like creating classes. TypeScript[6] and Dart[7] are both interesting languages with syntax more familiar to Java. There are a lot more languages that compile to javascript that I haven't mentioned[8].

It's possible that GWT and Java are the best fit for you, but don't pigeonhole yourself by thinking that they are the only good options out there.

[1] http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor... [2] https://github.com/documentcloud/underscore/blob/master/unde... [3] https://github.com/documentcloud/backbone/blob/master/backbo... [4] http://coffeescript.org/ [5] http://arcturo.github.com/library/coffeescript/02_syntax.htm... [6] http://www.typescriptlang.org/ [7] http://www.dartlang.org/ [8] https://github.com/jashkenas/coffee-script/wiki/List-of-lang...

SeanLuke · 2012-10-01 · Original thread
> The scope of a parameter, local variable, or local function declared within a function declaration (including a constructor, member function, or member accessor declaration) or function expression is the body of that function declaration or function expression.

This thing claims to be meant for "application-scale" JavaScript, and yet doesn't repair even JavaScript's most notorious error?

A suggestion to the authors. Purchase this book:

http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

... then go through the book with a fine-tooth comb, and every time it describes something as a "bad part" or an "awful part", delete or fix that misfeature in TypeScript.

vibrunazo · 2012-05-23 · Original thread
I've heard that same argument for a long time from PHP people. Yea, these are all but tools we use for the job. But bottom line is, some tools are just worse than others at pretty much any real practical use. [1] You make it sound like you've read the Javascript: The Good Parts book [2]. I've read it too, and it's a great book I recommend for anyone who must work with Javascript and have no way out of it. But keep in mind that an important premise of the book is aid those who are in this position where they can't run away from Javascript. As shown by this thread of languages that compile to it, it's often perfectly possible to dodge the shortcomings of JS by just not using it. You shouldn't torture yourself for no good reason. If you are in a position where you must work with JavaScript. Then I recommend reading this book to learn to stay away from the bad parts, as you said. But if you can work with any of the compilable languages, I highly recommend you stay away from JS as much as you can.

I would repeat the exact same argument for using SASS or LESS instead of CSS. There is no good reason to torture yourself with CSS instead of these better languages. It's very clear that there is such thing as one language that is much better than another in every practical sense.

[1] http://www.flickr.com/photos/raindrift/sets/7215762949290803...

[2] http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

anvaka · 2012-02-15 · Original thread
That's right! I love the discovery part of these visualizations. It helped me to find proper books many times - the graph drawing library is a result of such discovery.

I wanted to learn JavaScript. So I read a book recommended by my old Silverlight-based visualization, and developed the library.

I believe recommendation was successful. The book is Crockford's "JavaScript: The good parts" - http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

iKnowKungFoo · 2011-10-18 · Original thread
1. Learn JavaScript (the language)

http://eloquentjavascript.net/ http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

2. Learn jQuery (a JavaScript library)

http://jquery.com/ http://www.amazon.com/jQuery-Action-Second-Bear-Bibeault/dp/...

3. Learn SQL (the language)

http://www.amazon.com/Sams-Teach-Yourself-SQL-Minutes/dp/067...

4. Pick an implementation

MySQL, PostgreSQL, SQL Server, Oracle

----------------------------------

After that, most application development languages are just syntax. Pick what feels best.

Learn how to use Ajax to tie client-side requests to server-side requests and you're marketable.

andrewcooke · 2011-06-01 · Original thread
Effective Java is the best book for general Java that I know - http://www.amazon.com/Effective-Java-Programming-Language-Gu... It's not a tutorial, but a collection of recommendations that could take you from just-learnt to competent.

Very slim, and very good - Javascript: The Good Parts http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

For a C reference, Harbison & Steele is excellent - http://www.amazon.com/Reference-Manual-Samuel-P-Harbison/dp/...

S_A_P · 2010-10-21 · Original thread
besides by "doing it" I say bulletproof web design is a good book to start with. http://www.amazon.com/Bulletproof-Web-Design-flexibility-pro...

javascript- the good parts could also be helpful http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

www.jquery.com smashingmagazine.com ajaxian.com

all helpful

siculars · 2010-09-23 · Original thread
JavaScript: The Good Parts, http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...

Watch Crockford on Javascript at ydn: http://developer.yahoo.net/blogs/theater/archives/douglas_cr...

Watch @ryah on nodejs at ydn: http://www.yuiblog.com/blog/2010/05/20/video-dahl/ (and the other javascript related videos linked on that page)

limist · 2010-07-18 · Original thread
If you like this article, you'll love the book "Javascript: The Good Parts":

http://www.amazon.com/JavaScript-Good-Parts-Douglas-Crockfor...