Skip to content

Instantly share code, notes, and snippets.

View killtheliterate's full-sized avatar

Garrett Dawson killtheliterate

View GitHub Profile
window.fetch('/endpoing', {
method: 'POST',
body: new window.FormData(file)
})
// add something to check for 200 etc.
.then(res => res.json())
.then(console.log)
.catch(console.error)
})
@killtheliterate
killtheliterate / install.sh
Last active December 18, 2016 18:13
neobundle for neovim
#!/bin/sh
# Standalone installer for Unixs
# Original version is created by shoma2da
# https://github.com/shoma2da/neobundle_installer
# Installation directory
BUNDLE_DIR=~/.nvim/bundle
INSTALL_DIR=$BUNDLE_DIR/neobundle.vim
if [ -e $INSTALL_DIR ]; then
@killtheliterate
killtheliterate / redux-form.js
Created November 18, 2016 17:52
redux-form stuff
<form onSubmit={ }>
<div className="form-group">
<label className="form-check" htmlFor="send-chat">
<Field
name="sendChat"
id="send-chat"
component="input"
type="checkbox"
onChange={ this.props.handleSubmit(this.props.initialValues, 'sendChat') }
/>
@killtheliterate
killtheliterate / index.js
Last active July 1, 2016 00:05
requirebin sketch
var E = require('events')
var os = require('observable-socket')
var Rx = require('rxjs')
var receive = new Rx.Subject()
var send = new Rx.Subject()
var sock
@killtheliterate
killtheliterate / index.js
Last active June 29, 2016 19:39
requirebin sketch
var Rx = require('rxjs')
var subject = Rx.Observable.webSocket('wss://echo.websocket.org')
subject.next(JSON.stringify('one'))
subject.subscribe(
function (msg) {
console.log('a', msg)
},
@killtheliterate
killtheliterate / keybase.md
Created April 13, 2016 02:14
Keybase Pruuf

Keybase proof

I hereby claim:

  • I am killtheliterate on github.
  • I am garrettdawson (https://keybase.io/garrettdawson) on keybase.
  • I have a public key ASCFvei0_EjnVKPEJWnx6325dUmajzehdLozZVz6nA1V3Ao

To claim this, I am signing this object:

$sprites: sprite-map("sprites/*.png");
$sprites-retina: sprite-map("sprites-retina/*.png");
@mixin sprite-background($name) {
background-image: sprite-url($sprites);
background-position: sprite-position($sprites, $name);
background-repeat: no-repeat;
display: block;
height: image-height(sprite-file($sprites, $name));
width: image-width(sprite-file($sprites, $name));
@killtheliterate
killtheliterate / gist:5904551
Last active December 19, 2015 05:29
Dapper Drupal - Reference for a presentation by myself and @pixel_whip
Links presented in http://bit.ly/11Unm7E
Photo Credits:
Slide 1 - http://bit.ly/141n1US
Slide 4 - http://bit.ly/12ifyN0
Folks I talked with:
Stanford Web Services - http://stanford.io/16qmvQA
Kalamuna - http://bit.ly/19fE7E5
Code Enigma - http://bit.ly/14QwLSQ
@killtheliterate
killtheliterate / CMakeCache.txt
Created April 19, 2012 16:29
Homebrew log file
# This is the CMakeCache file.
# For build in directory: /tmp/homebrew-mysql-5.5.20-tanT/mysql-5.5.20
# It was generated by CMake: /usr/local/Cellar/cmake/2.8.8/bin/cmake
# You can edit this file to change values found and used by cmake.
# If you do not want to change any of the values, simply exit the editor.
# If you do want to change a value, simply edit, save, and exit the editor.
# The syntax for the file is as follows:
# KEY:TYPE=VALUE
# KEY is the name of a variable in the cache.
# TYPE is a hint to GUI's for the type of VALUE, DO NOT EDIT TYPE!.