Friday, December 2, 2011

Principles of Writing Consistent, Idiomatic JavaScript


Important, Non-Idiomatic Stuff:

Code Quality: Awesome Tools, Resources & References

Get Smart

The following should be considered 1) incomplete, and 2) REQUIRED READING. I don't always agree with the style written by the authors below, but one thing is certain: They are consistent. Furthermore, these are authorities on the language.

Build & Deployment Process

Projects should always attempt to include some generic means by which source can be compressed in preparation for production use. Some popular and proven tools include the JavaScript-based Uglify.js, as well as the Java-based Google Closure Compiler and YUI Compressor. Choose one and support it.
You can now find a functional, generic "build kit" in the /kits directory of this repository. Usage is easy: 1) copy the contents of a kit found in /kits to a new working directory, 2) save your project .js file in the /src directory, 3) put the name of the project in project.txt, 4) run make from command line. (Even easier directions: replace occurrences of "foo")

Test Facility

Projects must include some form of unit, reference, implementation or functional testing. Use case demos DO NOT QUALIFY as "tests".

Table of Contents

No comments: