Skip to content

Instantly share code, notes, and snippets.


dwayne. dwyn

View GitHub Profile

Pair Programming

What is pair programming? (Christina)

Pair programming is an agile software development technique in which two programmers work together at one workstation.

One member, the driver, writes code while the other, the observer or navigator, reviews each line of code as it is typed in. The two people work together to design, code and test user stories.

  • perhaps talk about what pair programming looks like at Artsy today (ad-hoc).
bvaughn /
Last active Jun 19, 2021
React lifecycle cheatsheet

React lifecycle cheatsheet

Method Side effects1 State updates2 Example uses
componentWillMount Constructor equivalent for createClass
render Create and return element(s)
componentDidMount DOM manipulations, network requests, etc.
componentWillReceiveProps Update state based on changed props
ericelliott /
Last active Jul 26, 2021
The distinction between anonymous functions and lambdas in JavaScript.

TL;DR - Lambda means "function expression used as data".

Anonymous function means "function without a name".

This is one of the relatively few cases where the Wikipedia definition of a word, while not entirely wrong, is misleading. Lambdas and anonymous functions are distinct ideas.

These ideas are commonly confused because in many programming languages (and lambda calculus) all lambdas are anonymous or vise verse.

In JavaScript, not all lambdas are anonymous, and not all anonymous functions are used as lambdas, so the distinction has some practical meaning.

kimchaily / alfred2-openNewChromeWindow
Created Apr 16, 2015
Alfred workflow. Open a new window in Chrome and if URL given, then go to that URL
View alfred2-openNewChromeWindow
on alfred_script(q)
if not (q starts with "http://")
set q to "http://" & q
end if
tell application "/Applications/Google"
make new window
set URL of active tab of window 1 to q
end tell
end alfred_script
itsmattsoria / gistfil1.textile
Last active Jul 26, 2021
Mac Terminal Cheat Sheet
View gistfil1.textile


Key/Command Description
Tab Auto-complete files and folder names
Ctrl + A Go to the beginning of the line you are currently typing on
Ctrl + E Go to the end of the line you are currently typing on
Ctrl + U Clear the line before the cursor
Ctrl + K Clear the line after the cursor
Ctrl + W Delete the word before the cursor
Ctrl + T Swap the last two characters before the cursor
ryandeussing / gist:5667094
Created May 29, 2013
Find and kill a zombie shotgun server
View gist:5667094
$ ps ax | grep shotgun
11152 s000 R+ 0:00.00 grep shotgun
10766 s001 S+ 0:00.60 /Users/ryandeussing/.rvm/gems/ruby-1.9.3-p429@sinatra/bin/shotgun
$ kill -9 10766