JavaScript: The Good Parts (Paperback)
暫譯: JavaScript:優雅之處

Douglas Crockford

買這商品的人也買了...

相關主題

商品描述

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.

商品描述(中文翻譯)

大多數程式語言都有好壞之分,但 JavaScript 的壞的部分卻特別多,因為它是在急促的情況下開發和發布的,未經過精煉。這本權威的書籍剝離了這些壞特性,揭示了一個比整個語言更可靠、可讀性更高且更易於維護的 JavaScript 子集——這個子集可以用來創建真正可擴展和高效的代碼。

作者道格拉斯·克羅克福德(Douglas Crockford)被許多開發社群的人視為 JavaScript 的專家,他指出了使 JavaScript 成為一種出色的物件導向程式語言的眾多好想法——例如函數、鬆散類型、動態物件和表達性物件字面量表示法。不幸的是,這些好想法與壞的甚至是糟糕的想法混合在一起,例如基於全域變數的程式模型。

當 Java 小應用程式失敗時,JavaScript 成為了網路的預設語言,使其受歡迎程度幾乎完全不依賴於其作為程式語言的特質。在《JavaScript: The Good Parts》中,克羅克福德最終深入挖掘這堆充滿好意和失誤的內容,為你詳細介紹 JavaScript 中所有真正優雅的部分,包括:

- 語法
- 物件
- 函數
- 繼承
- 陣列
- 正規表達式
- 方法
- 風格
- 美麗的特性

真正的美在於?當你隨著這本書所呈現的 JavaScript 子集向前邁進時,你也會避免需要「重新學習」所有的壞部分。當然,如果你想了解更多關於壞部分及其糟糕用法的資訊,只需參考其他任何 JavaScript 書籍。

透過《JavaScript: The Good Parts》,你將發現一種美麗、優雅、輕量且高度表達性的語言,讓你能夠創建有效的代碼,無論你是在管理物件庫還是僅僅想讓 Ajax 運行得更快。如果你為網路開發網站或應用程式,這本書絕對是必備之作。