News for hackers. Stuff that matters.
Re:Say What You Mean (in JavaScript) by aaronblohowiak on Tuesday May 18, 2010 @04:50PM (#1359017)
my personal favorite is:

function f(p1, p2, p3){ p2 || ( p2 = "default); }

and i have a buddy that likes to do "poor man's unless":

if(something && other_thing || third_thing); else{ }

which helps you from having to figure out the logical inversion or have the ! to track down, but is a little weird

There are no comments on this comment yet.