Murakami Sale
 
 

Recently Viewed clear list


Original Essays | August 18, 2014

Ian Leslie: IMG Empathic Curiosity



Today, we wonder anxiously if digital media is changing our brains. But if there's any time in history when our mental operations changed... Continue »
  1. $18.89 Sale Hardcover add to wish list

spacer
Qualifying orders ship free.
$21.00
List price: $39.99
Used Trade Paper
Ships in 1 to 3 days
Add to Wishlist
Qty Store Section
1 Beaverton Internet- JavaScript

Maintainable JavaScript

by

Maintainable JavaScript Cover

 

Synopses & Reviews

Publisher Comments:

You may have definite ideas about writing code when working alone, but team development requires that everyone use the same approach. With the JavaScript practices in this book—including code style, programming tips, and automation—you will learn how to write maintainable code that other team members can easily understand, adapt, and extend.

Author Nicholas Zakas assembled this collection of best practices as a front-end tech leader at Yahoo!, after completing his own journey from solo hacker to team player. He also includes rules recommended by other industry authorities. Use these tips and techniques to help your team set aside individual preferences and function at a higher level.

  • Establish specific code conventions for your team
  • Use tools such as JSLint and JSHint to keep your team on track
  • Adopt style guidelines, such as basic formatting, to help your team produce uniform code
  • Apply several programming practices to solve problems and improve code quality
  • Create an automated JavaScript build system using a variety of utilities
  • Integrate browser-based JavaScript testing with tools such as the YUI Test Selenium Driver

Synopsis:

When you're writing code alone, you have a lot of leeway. But when you start writing code as part of a team, you need to think harder about the decisions you make. This book will help you do that.

When you write code in a team setting, will other developers be able to understand what you did? Did you organize your code in such a way that it's easy to adapt and extend? Will your code survive once you're gone? Maintainable JavaScript doesn't just recommend a set of guidelines, it examines guidelines being used and recommended by others in the industry, so you get a feel for what's common in well-run JavaScript projects.

Save a copy of this book now. It's the only resource that focuses solely on JavaScript conventions.

About the Author

Nicholas C. Zakas is a front-end consultant, author, and speaker. He worked at Yahoo! for almost five years, where he was front-end tech lead for the Yahoo! homepage and a contributor to the YUI library. He is the author of Professional JavaScript for Web Developers (Wrox, 2012), Professional Ajax (Wrox, 2007), and High Performance JavaScript(OReilly, 2010). Nicholas is a strong advocate for development best practices including progressive enhancement, accessibility, performance, scalability, and maintainability. He blogs regularly at http://www.nczonline.net/ and can be found on Twitter via @slicknet.

Table of Contents

Introduction; Preface; Conventions Used in This Book; Using Code Examples; Safari® Books Online; How to Contact Us; Style Guidelines; Chapter 1: Basic Formatting; 1.1 Indentation Levels; 1.2 Statement Termination; 1.3 Line Length; 1.4 Line Breaking; 1.5 Blank Lines; 1.6 Naming; 1.7 Literal Values; Chapter 2: Comments; 2.1 Single-Line Comments; 2.2 Multiline Comments; 2.3 Using Comments; 2.4 Documentation Comments; Chapter 3: Statements and Expressions; 3.1 Brace Alignment; 3.2 Block Statement Spacing; 3.3 The switch Statement; 3.4 The with Statement; 3.5 The for Loop; 3.6 The for-in Loop; Chapter 4: Variables, Functions, and Operators; 4.1 Variable Declarations; 4.2 Function Declarations; 4.3 Function Call Spacing; 4.4 Immediate Function Invocation; 4.5 Equality; 4.6 eval(); 4.7 Primitive Wrapper Types; Programming Practices; Chapter 5: Loose Coupling of UI Layers; 5.1 What Is Loose Coupling?; 5.2 Keep JavaScript Out of CSS; 5.3 Keep CSS Out of JavaScript; 5.4 Keep JavaScript Out of HTML; 5.5 Keep HTML Out of JavaScript; Chapter 6: Avoid Globals; 6.1 The Problems with Globals; 6.2 Accidental Globals; 6.3 The One-Global Approach; 6.4 The Zero-Global Approach; Chapter 7: Event Handling; 7.1 Classic Usage; 7.2 Rule #1: Separate Application Logic; 7.3 Rule #2: Don't Pass the Event Object Around; Chapter 8: Avoid Null Comparisons; 8.1 Detecting Primitive Values; 8.2 Detecting Reference Values; 8.3 Detecting Properties; Chapter 9: Separate Configuration Data from Code; 9.1 What Is Configuration Data?; 9.2 Externalizing Configuration Data; 9.3 Storing Configuration Data; Chapter 10: Throw Your Own Errors; 10.1 The Nature of Errors; 10.2 Throwing Errors in JavaScript; 10.3 Advantages of Throwing Errors; 10.4 When to Throw Errors; 10.5 The try-catch Statement; 10.6 Error Types; Chapter 11: Don't Modify Objects You Don't Own; 11.1 What Do You Own?; 11.2 The Rules; 11.3 Better Approaches; 11.4 A Note on Polyfills; 11.5 Preventing Modification; Chapter 12: Browser Detection; 12.1 User-Agent Detection; 12.2 Feature Detection; 12.3 Avoid Feature Inference; 12.4 Avoid Browser Inference; 12.5 What Should You Use?; Automation; Chapter 13: File and Directory Structure; 13.1 Best Practices; 13.2 Basic Layout; Chapter 14: Ant; 14.1 Installation; 14.2 The Build File; 14.3 Running the Build; 14.4 Target Dependencies; 14.5 Properties; 14.6 Buildr; Chapter 15: Validation; 15.1 Finding Files; 15.2 The Task; 15.3 Improving the Target; 15.4 Other Improvements; 15.5 Buildr Task; Chapter 16: Concatenation and Baking; 16.1 The Task; 16.2 Line Endings; 16.3 Headers and Footers; 16.4 Baking Files; Chapter 17: Minification and Compression; 17.1 Minification; 17.2 Compression; Chapter 18: Documentation; 18.1 JSDoc Toolkit; 18.2 YUI Doc; Chapter 19: Automated Testing; 19.1 YUI Test Selenium Driver; 19.2 Yeti; 19.3 PhantomJS; 19.4 JsTestDriver; Chapter 20: Putting It Together; 20.1 Missing Pieces; 20.2 Planning the Build; 20.3 Using a CI System; JavaScript Style Guide; Indentation; Line Length; Primitive Literals; Operator Spacing; Parentheses Spacing; Object Literals; Comments; Variable Declarations; Function Declarations; Naming; Strict Mode; Assignments; Equality Operators; Ternary Operator; Statements; White Space; Things to Avoid; JavaScript Tools; Build Tools; Documentation Generators; Linting Tools; Minification Tools; Testing Tools; Colophon;

Product Details

ISBN:
9781449327682
Author:
Zakas, Nicholas C
Publisher:
O'Reilly Media
Author:
Zakas, Nicholas C.
Subject:
Programming Languages - CGI, Javascript, Perl, VBScript
Subject:
Computer Languages-CGI
Subject:
clean code,;html5;javascript;large scale development;web development
Subject:
CourseSmart Subject Description
Copyright:
Edition Description:
Print PDF
Publication Date:
20120631
Binding:
TRADE PAPER
Language:
English
Pages:
242
Dimensions:
9.19 x 7 in

Related Subjects

Computers and Internet » Computer Languages » Javascript
Computers and Internet » Internet » JavaScript
Computers and Internet » Internet » Web » Web Programming
Computers and Internet » Networking » General
Computers and Internet » Software Engineering » General
Science and Mathematics » Mathematics » General

Maintainable JavaScript Used Trade Paper
0 stars - 0 reviews
$21.00 In Stock
Product details 242 pages O'Reilly Media - English 9781449327682 Reviews:
"Synopsis" by ,

When you're writing code alone, you have a lot of leeway. But when you start writing code as part of a team, you need to think harder about the decisions you make. This book will help you do that.

When you write code in a team setting, will other developers be able to understand what you did? Did you organize your code in such a way that it's easy to adapt and extend? Will your code survive once you're gone? Maintainable JavaScript doesn't just recommend a set of guidelines, it examines guidelines being used and recommended by others in the industry, so you get a feel for what's common in well-run JavaScript projects.

Save a copy of this book now. It's the only resource that focuses solely on JavaScript conventions.

spacer
spacer
  • back to top
Follow us on...




Powell's City of Books is an independent bookstore in Portland, Oregon, that fills a whole city block with more than a million new, used, and out of print books. Shop those shelves — plus literally millions more books, DVDs, and gifts — here at Powells.com.