Programming Books C Java PHP Python Learn more Browse Programming Books
JavaScript: The Good Parts: The Good Parts and over one million other books are available for Amazon Kindle. Learn more

Sorry, this item is not available in
Image not available for
Color:
Image not available

To view this video download Flash Player

 


or
Sign in to turn on 1-Click ordering
Sell Us Your Item
For a $4.55 Gift Card
Trade in
More Buying Choices
Have one to sell? Sell yours here
Start reading JavaScript: The Good Parts: The Good Parts on your Kindle in under a minute.

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.

JavaScript: The Good Parts [Paperback]

by Douglas Crockford
4.2 out of 5 stars  See all reviews (289 customer reviews)

Buy New
$17.39 & FREE Shipping on orders over $35. Details
Rent
$12.94
In Stock.
Ships from and sold by Amazon.com. Gift-wrap available.
In Stock.
Rented by RentU and Fulfilled by Amazon.
Want it tomorrow, April 25? Choose One-Day Shipping at checkout. Details
Free Two-Day Shipping for College Students with Amazon Student

Formats

Amazon Price New from Used from
Kindle Edition $9.60  
Paperback $17.39  
Like this book? Find similar titles in the O'Reilly Bookstore.

Book Description

May 2008 0596517742 978-0596517748 1st

Most programming languages contain good and bad parts, but JavaScript has more than its share of the bad, having been developed and released in a hurry before it could be refined. This authoritative book scrapes away these bad features to reveal a subset of JavaScript that's more reliable, readable, and maintainable than the language as a whole—a subset you can use to create truly extensible and efficient code.

Considered the JavaScript expert by many people in the development community, author Douglas Crockford identifies the abundance of good ideas that make JavaScript an outstanding object-oriented programming language-ideas such as functions, loose typing, dynamic objects, and an expressive object literal notation. Unfortunately, these good ideas are mixed in with bad and downright awful ideas, like a programming model based on global variables.

When Java applets failed, JavaScript became the language of the Web by default, making its popularity almost completely independent of its qualities as a programming language. In JavaScript: The Good Parts, Crockford finally digs through the steaming pile of good intentions and blunders to give you a detailed look at all the genuinely elegant parts of JavaScript, including:

  • Syntax
  • Objects
  • Functions
  • Inheritance
  • Arrays
  • Regular expressions
  • Methods
  • Style
  • Beautiful features

The real beauty? As you move ahead with the subset of JavaScript that this book presents, you'll also sidestep the need to unlearn all the bad parts. Of course, if you want to find out more about the bad parts and how to use them badly, simply consult any other JavaScript book.

With JavaScript: The Good Parts, you'll discover a beautiful, elegant, lightweight and highly expressive language that lets you create effective code, whether you're managing object libraries or just trying to get Ajax to run fast. If you develop sites or applications for the Web, this book is an absolute must.


Frequently Bought Together

JavaScript: The Good Parts + JavaScript: The Definitive Guide: Activate Your Web Pages (Definitive Guides) + Secrets of the JavaScript Ninja
Price for all three: $70.37

Buy the selected items together


Editorial Reviews

Book Description

Unearthing the Excellence in JavaScript

About the Author

Douglas Crockford is a Senior JavaScript Architect at Yahoo!, well known for introducing and maintaining the JSON (JavaScript Object Notation) format. He's a regular speaker at conferences on advanced JavaScript topics, and serves on the ECMAScript committee.


Product Details

  • Paperback: 176 pages
  • Publisher: O'Reilly Media; 1st edition (May 2008)
  • Language: English
  • ISBN-10: 0596517742
  • ISBN-13: 978-0596517748
  • Product Dimensions: 2.8 x 3.6 x 0.2 inches
  • Shipping Weight: 8 ounces (View shipping rates and policies)
  • Average Customer Review: 4.2 out of 5 stars  See all reviews (289 customer reviews)
  • Amazon Best Sellers Rank: #2,355 in Books (See Top 100 in Books)

More About the Author

Douglas Crockford is a Senior JavaScript Architect at Yahoo!, well known for introducing and maintaining the JSON (JavaScript Object Notation) format. He's a regular speaker at conferences on advanced JavaScript topics, and serves on the ECMAScript committee.

Customer Reviews

Most Helpful Customer Reviews
484 of 494 people found the following review helpful
Format:Paperback|Verified Purchase
Do you struggle when creating objects in Javascript?
Do you find the syntax to be non-intuitive and frustrating?
Do you know the difference between using a function as an object vs using an object literal?
Do you know how using object literals can simplify your code and create something similar to namespaces?
Do you know how to augment the type system -- for example, if wanted all strings to have a trim() method?
Do you know why the "new" statement is so dangerous? Do you know an alternative that eliminates the use of "new" entirely?

These are some of the topics that the book touches upon.

This book is aimed at someone with intermediate programming experience that wants to know the best way to create and use objects, arrays, types, etc. Crockford takes his experience with Javascript to show you best practices coding techniques and styles to use with Javascript. In addition, the book provides insights into what makes Javascript so confusing and what can be done about it.

You might ask "Isn't this stuff already covered in other books that I have?" The answer is no. For one, most other books use a psuedo-classical coding style (see below) to explain objects that is a source of confusion.

Javascript can be very confusing, especially for programmers who have extensive experience in other C-based languages (like myself). Writing good Javascript that uses objects, methods, etc. is hard. In Javascript, if you want to create objects, use inheritance and create methods, you have several different ways to write your code and it's difficult to know what the strengths and weaknesses of each are.

Crockford explains the problem plainly. Other C-based languages use class inheritance (Crockford calls this classical inheritance).
Read more ›
Was this review helpful to you?
113 of 121 people found the following review helpful
5.0 out of 5 stars Beautiful book May 16, 2008
Format:Paperback|Verified Purchase
This is a beautiful book.

First of all - at only 170 pages it is short. Even though some of the key points are repeated through the book it's dense with information. You don't need any JavaScript experience, but it's not a "beginning programming" book so if you haven't been programming before this is not the right book for you.

Reading this book a couple of times will give you an appreciation for the JavaScript language that you almost certainly didn't have before. It'll give you tools to write better programs that you and others will actually be able to maintain over time.

I've learned lots of little things that I maybe knew from experience, but now I _know_ and I know why.

This book will help you battle with JavaScript rather than against it.
Was this review helpful to you?
148 of 163 people found the following review helpful
Format:Kindle Edition|Verified Purchase
I'm a long-time C, C++, and Java programmer (videogames, predominantly) learning Javascript to do some web work, so I picked up this book because the reviews were good and the notion appealed to me - learn the subset of this rather sloppy language that you can use as a good language.

My TL;DR version of the review: this book is a hodgepodge of different information about the language, but some of it is so complicated it'll go immediately over the heads of new programmers, and then some of it is so mundane (even pedantic, talking about very specific aspects of coding styles) it felt goofy and out of place. It seems to me that any specific individual reading this book won't really find more than one or two chapters very relevant. I give it 3 stars because the useful parts were useful to me, but I skimmed and ignored 80+% of the book.

Crockford's writing is personable and clear, and the book's organization is straightforward. Here's my chapter-by-chapter breakdown. Note that this is all from my perspective, what I personally found useful or not, but my point is, while other readers will certainly disagree with me about what was useful, I have trouble imagining any one person finding more than about 20% of the book useful.

Chapter 1 is an introduction and high-level explanation of the point of the book.

Chapter 2 covers basic grammar and the likes, which was helpful though it's not aimed at any particular familiarity with other languages so it's trying to be comprehensive, which meant that as an experienced programmer in other languages I had to skim it and just look for differences with what I'm already used to.
Read more ›
Was this review helpful to you?
45 of 49 people found the following review helpful
Format:Paperback|Verified Purchase
Serious JavaScript programming requires strong discipline to avoid many pitfalls that are somewhat encouraged by the language itself. The author is very aware of this problem and wrote a small, but very dense book, full of useful advices that comes from somebody who has doing sophisticated JavaScript programming for a long time. Crockford is very opinionated, and I don't always agree 100% with his suggestions, nevertheless, even whenever I disagree, I find his points are worth reading, his opinion is always valuable. This book would serve well both veteran JavaScript developers and programmers that, coming from different languages, may get lost among JavaScript's idiosyncrasies.
Comment | 
Was this review helpful to you?
12 of 12 people found the following review helpful
Format:Paperback
Weighing in at 140+ pages of content, this book cuts through the obscurities, pleasantries, and filler found in most technical books. Instead, this book dives straight into the heart of the JavaScript language. It presents the clearest comprehensive explanation of what makes JavaScript a great programming language that I've encountered to date. It nails the important concepts, like JavaScript's: object oriented nature, its classless (pseudoclassical) nature, and functional nature. While covering the fundamentals like JavaScript's: functions, lexical scoping, lambdas, prototypal inheritance, and functional inheritance.

This book's size makes it approachable for all audiences, its style is terse and concise. This book has the potential to do for JavaScript, what Richie's inspirational classic the C Programming Language did for the C language.

JavaScript is the programming language of the web (AJAX), and this book will guide you through the good parts of this often misunderstood language - while this book is an excellent reference, it is not intended to replace JavaScript: The Definitive Guide, you'll do best to have both these books on hand.

If you enjoyed (or are considering) this book then you may want to hear more of what Douglas Crockford has to say, check out his great JavaScript video series on the YUI Theater.
Comment | 
Was this review helpful to you?
Most Recent Customer Reviews
5.0 out of 5 stars Excellent book on a terrible languge.
Javascript, the language that should have been a lot better. Fortunately there are enough good parts to make it workable but ugh. Read more
Published 22 hours ago by G. Powell
1.0 out of 5 stars Inconsistent, examples does not work as expected.
I borrow this book and willing to buy it, but it is filled with errors and examples does not work as expected. Read more
Published 4 days ago by José
5.0 out of 5 stars Only wish I read this sooner
The book is thin but packs a punch. The content is well chosen and author provides welcome and amusing commentary. Read more
Published 8 days ago by Pen Name
5.0 out of 5 stars excellent book
JavaScript is not an easy language. That's not a big secret. The author, however, does a great job explaining the key parts of the language. Read more
Published 9 days ago by Arik Cohen
5.0 out of 5 stars Excelent JavaScript book
This is a short book that every programmer and web developer has to have! All the power of JavaScript in (just) 150ish pages. Read more
Published 17 days ago by nemcaninz
4.0 out of 5 stars Important book now more than ever but also a bit dated
First of all this book is very good for what it is; describing the genesis of the Javascript language, why things work the way they do, and how to make the best use of its good... Read more
Published 19 days ago by Jasha
5.0 out of 5 stars Great book on JS
I am a fairly new programmer, so I do not know how my review will really help anyone. However this book took my understanding of Javascript to the next level. Read more
Published 20 days ago by Leonardo Lee
5.0 out of 5 stars Definite read for JavaScript developers.
Definite read for JavaScript developers. Learn to use the good parts. Avoid the bad parts. All with a bit of humor.
Published 21 days ago by Andrew Stevko
2.0 out of 5 stars A more accurate title would be "JavaScript - The Bad Parts"
I purchased this book because it is so highly recommended. But, I was turned off by the absolutes that Mr Crockford espouses. Read more
Published 25 days ago by David Bush
5.0 out of 5 stars Very good. Condesed knowlege.
Very good. Before I liked the long manuals that explained every detail of something. I'm leaning now more to the short books that do contain a lot of information in small space. Read more
Published 25 days ago by J. I. Seco Sanz
Search Customer Reviews
Only search this product's reviews
ARRAY(0xa4ef71bc)

What Other Items Do Customers Buy After Viewing This Item?


Forums

There are no discussions about this product yet.
Be the first to discuss this product with the community.
Start a new discussion
Topic:
First post:
Prompts for sign-in
 



Look for Similar Items by Category