Skip to content

Instantly share code, notes, and snippets.

@joshwnj
Created August 20, 2014 04:48
Show Gist options
  • Save joshwnj/a23f27df0f002849f183 to your computer and use it in GitHub Desktop.
Save joshwnj/a23f27df0f002849f183 to your computer and use it in GitHub Desktop.
// ----
// 1. natural spacing
var foo = 'foo';
var bar = 'bar';
var superCalaFragilistic = '...';
// ----
// 2. aligning the `=` sign
//
// Con: commits that cause realignment have ugly/misleading diffs
// (shows "3 lines changed" when it should only be "1 line changed".
// Imagine if we have 10+ things instead of 3...)
// Con: the 3 values are visually grouped, which doesn't make sense.
// Easier to read when you group LHS to RHS.
// Pro: ? people seem to like it
var foo = 'foo';
var bar = 'bar';
var superCalaFragilistic = '...';
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment