[wp-trac] [WordPress Trac] #15783: JavaScript Coding Standards
WordPress Trac
wp-trac at lists.automattic.com
Sun Dec 12 10:56:05 UTC 2010
#15783: JavaScript Coding Standards
-------------------------+--------------------------------------------------
Reporter: GamajoTech | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: trivial | Keywords:
-------------------------+--------------------------------------------------
Following up on scribu's and azaozz's comments in #15650, would a
JavaScript Coding Standards page on the Codex (equivalent to
http://codex.wordpress.org/WordPress_Coding_Standards and
http://codex.wordpress.org/CSS_Coding_Standards) be useful?
It would not only include the usual code formatting, whitespace, brace
position, semi-colon requirements etc, but also clarify on which code
patterns are preferable for performance, both for the specific dependency
library, and those that will give the smallest file when minified.
Another idea might be to introduce a file docblock that outlines which JS
library or other file dependencies the current file has.
Some references:
* http://javascript.crockford.com/code.html
* http://google-styleguide.googlecode.com/svn/trunk/javascriptguide.xml
* http://drupal.org/node/172169
--
Ticket URL: <http://core.trac.wordpress.org/ticket/15783>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list