Skip to content

Instantly share code, notes, and snippets.

View skellock's full-sized avatar

Steve Kellock skellock

View GitHub Profile
def on_load
find(self).apply_style :ilya_cell
find(self.contentView).apply_style :ilya_cell_content
end

Keybase proof

I hereby claim:

  • I am skellock on github.
  • I am skellock (https://keybase.io/skellock) on keybase.
  • I have a public key whose fingerprint is FD61 7500 F5FA 0F35 88D6 F9B8 E097 B344 BAAE 62D3

To claim this, I am signing this object:

@skellock
skellock / gist:b8513985e56b03a59963188803b4184e
Created April 26, 2016 13:23
Sends a shake command to each attach android device.
$ANDROID_HOME/platform-tools/adb devices | grep '\\t' | awk '{print $1}' | sed 's/\\s//g' | xargs -I {} $ANDROID_HOME/platform-tools/adb -s {} shell input keyevent 82
"ava": {
"babel": "inherit",
"files": [ "Tests/**/*.js", "!Tests/Setup.js" ],
"require": [
"babel-register",
"babel-polyfill",
"react-native-mock/mock",
"./Tests/Setup"
]
}
{
“presets”: [“react-native”]
}
// when given a name, it’ll enthusiastically greet them!!!!!
export default (name) => `Hello ${name}!`
import test from ‘ava’
import greeter from ‘./Greeter’
test(‘says hello’, t => {
t.is(greeter(‘World’), ‘Hello World!’)
})
const INITIAL_STATE = { value: 0 }
// do something important & significant
const increment = (state, action) => ({ value: state.value + 1 })
// our reducer
export default (state = INITIAL_STATE, action) => {
switch (action.type) {
case 'INCREMENT': return increment(state, action)
default: return state
import test from 'ava'
import reducer from './CounterReducer'
test('increment from a fresh state', t => {
const state = reducer(undefined, { type: 'INCREMENT' })
t.deepEqual(state, { value: 1 })
})
test('increment from a previous state', t => {
const state = reducer({ value: 68 }, { type: 'INCREMENT' })
import { put, call, select } from 'redux-saga/effects'
export function acquireDataFromSomewhere (numberOfThings) {
return new Promise((resolve, reject) => {
resolve(`here are ${numberOfThings} things`)
})
}
// Fires when we see TIME_TO_SHINE come through.
// Its pretty random what we do here.