(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
#!/bin/bash | |
# Installation: | |
# 1. Save this script to /some/bin/ssh-background | |
# 2. chmod 755 /some/bin/ssh-background | |
# 3. alias ssh=/some/bin/ssh-background | |
# 4. Configure your host colors below. | |
set_color() { | |
local HEX_FG=$1 | |
local HEX_BG=$2 |
// http://paulirish.com/2011/requestanimationframe-for-smart-animating/ | |
// http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating | |
// requestAnimationFrame polyfill by Erik Möller. fixes from Paul Irish and Tino Zijdel | |
// MIT license | |
(function() { | |
var lastTime = 0; | |
var vendors = ['ms', 'moz', 'webkit', 'o']; |
#!/usr/bin/env ruby | |
def is_mac? | |
RUBY_PLATFORM.downcase.include?("darwin") | |
end | |
def getc_input | |
# http://stackoverflow.com/a/174967/250407 | |
# http://bit.ly/PMZdKv | |
begin |
# Install Ruby | |
## =============================================== | |
- name: Install dependencies | |
apt: name=$item state=latest update_cache=yes | |
with_items: | |
- bison | |
- openssl | |
- libyaml-dev | |
- autoconf |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
// https://codepen.io/hartzis/pen/VvNGZP | |
class ImageUpload extends Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
file: '', | |
imagePreviewUrl: '' | |
}; | |
this._handleImageChange = this._handleImageChange.bind(this); | |
this._handleSubmit = this._handleSubmit.bind(this); |
import React, { SFC } from 'react'; | |
import { MapDispatchToPropsParam, MapStateToPropsParam } from 'react-redux'; | |
import { StateRoot } from 'reducers/types'; | |
import { AnyAction, Dispatch } from 'redux'; | |
// | |
// Helpers | |
// | |
const createSubType = <T extends any>() => <SubType extends T>(subType: SubType) => subType; |