Skip to content

Instantly share code, notes, and snippets.

#!/bin/sh
# Some things taken from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
green='\033[0;32m'
@tdowling
tdowling / introrx.md
Last active August 29, 2015 14:03 — forked from staltz/introrx.md

The introduction to Reactive Programming you've been missing

(by @andrestaltz)

So you're curious in learning this new thing called (Functional) Reactive Programming (FRP).

Learning it is hard, even harder by the lack of good material. When I started, I tried looking for tutorials. I found only a handful of practical guides, but they just scratched the surface and never tackled the challenge of building the whole architecture around it. Library documentations often don't help when you're trying to understand some function. I mean, honestly, look at this:

Rx.Observable.prototype.flatMapLatest(selector, [thisArg])

Projects each element of an observable sequence into a new sequence of observable sequences by incorporating the element's index and then transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence.

=Navigating=
visit('/projects')
visit(post_comments_path(post))
=Clicking links and buttons=
click_link('id-of-link')
click_link('Link Text')
click_button('Save')
click('Link Text') # Click either a link or a button
click('Button Value')
@tdowling
tdowling / .psqlrc
Created October 8, 2013 20:47 — forked from bidulock/.psqlrc
-- Include the hostname in the prompt, and add a * when in a transaction
-- The default PROMPT2 doesn't make it obvious enough nothing has been sent to the server yet
\set PROMPT1 '%M:%/%R%x%# '
\set PROMPT2 '> '
-- Always be in a transaction. It's safer this way
\set AUTOCOMMIT off
-- Turn the pager on always. This is best used with "export PAGER=less -S -F -X" added to your .bashrc
\pset pager always