WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #19592, comment 26


Ignore:
Timestamp:
03/03/12 21:08:23 (2 years ago)
Author:
azaozz
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #19592, comment 26

    initial v1  
    11Replying to [comment:25 soulseekah]: 
    22> Most of the warnings are "try to use only one {{{ --> var <--  }}}". Readability of JS code is severely impaired when fixing these... 
    3 >  
     3> ... 
    44> Most of these are best left alone, not really worth chasing down the 3 extra bytes here and there... 
    55 
    6 This is rather a question of coding standards not of trying to save few bytes. It is a good practice to declare all local variables at the beginning of each scope (i.e. have one `var ...;` at the top of each function). This actually helps readability and is preferred in most (all?) IDEs that have JS support. (It also seems to simplify the actual minifying in YUI Compressor).  
     6This is rather a question of coding standards not of trying to save few bytes. It is a good practice to declare all local variables at the beginning of each scope (i.e. have one `var ...;` at the top of each function). This actually helps readability and is preferred in most (all?) IDEs that have JS support. (It also seems to simplify the minifying in YUI Compressor).  
    77 
    88> Overall should we be listening to some sort of Lint instead of a compressor...