Skip to content

Instantly share code, notes, and snippets.

View lukehedger's full-sized avatar
🍵
(ू˃̣̣̣̣̣̣︿˂̣̣̣̣̣̣ ू)

Luke Hedger lukehedger

🍵
(ू˃̣̣̣̣̣̣︿˂̣̣̣̣̣̣ ू)
View GitHub Profile
0x92Ea561678D3b3D9f587C4089C5019B32abD9F5f
// For each unit test you write,
// answer these questions:
describe('What component aspect are you testing?', () => {
it('What should the feature do?', () => {
const actual = 'What is the actual output?'
const expected = 'What is the expected output?'
expect(actual).toEqual(expected)
@lukehedger
lukehedger / r-pi-vnc.md
Last active August 9, 2018 04:43
Setup VNC between Raspberry Pi and OSX
@lukehedger
lukehedger / tape-browser.sh
Created June 9, 2016 09:33
Run tests in browser
npm-run browserify -t babelify test/ | npm-run browser-run -p 2222 | npm-run faucet
@lukehedger
lukehedger / react-render-html-tags.js
Last active October 7, 2018 00:13
Render HTML elements defined in JSON to JSX
import React from 'react';
const Component = (props, context) => {
const { elements } = this.props;
return (
<div>
{elements.map( (element, i) => {
@lukehedger
lukehedger / es6-class.js
Created March 9, 2016 17:53
Just playing around with ES6 Classes
class Klass {
constructor() {
console.log('hello class!')
}
static util(a, b) {
return a + b
}
render() {
@lukehedger
lukehedger / zsh-alias.sh
Created February 29, 2016 12:39
ZSH aliases
# list aliases
alias
# add alias
alias name='command'
# remove alias
unalias name
@lukehedger
lukehedger / view-kill-process.sh
Created February 29, 2016 11:16
View and kill processes
# view all processes
ps -ax
# filter processes
ps -ax | grep <process-name>
# kill process
kill <process-PID>