Skip to content

Instantly share code, notes, and snippets.

View antialias's full-sized avatar

Thomas Hallock antialias

View GitHub Profile
{
"claim": {
"claim_id": "100004-0",
"claim_group_id": "100004",
"source_system": "Edge",
"status": "Reopened",
"claim_group_status": null,
"closed": false,
"severity_score": null,
"received_date": "1926-03-01T00:00:00+00:00",
{
"meta": {
"theme": "stackoverflow"
},
"basics": {
"name": "Thomas Hallock",
"label": "",
"picture": "",
"email": "hallock@gmail.com",
"phone": "+1.512.775.6652",
@antialias
antialias / simple-thunk.js
Created August 16, 2018 19:59
Simple Thunk API Request
import {
API_BUTTON_CLICK,
API_BUTTON_CLICK_SUCCESS,
API_BUTTON_CLICK_ERROR,
} from './actions/consts';
import { getDataFromAPI } from './api';
const getDataStarted = () => ({ type: API_BUTTON_CLICK });
const getDataSuccess = data => ({ type: API_BUTTON_CLICK_SUCCESS, payload: data })
const getDataError = message => ({ type: API_BUTTON_CLICK_ERROR, payload: message });
@antialias
antialias / antialias-authored-npm-packages
Created January 13, 2017 04:34
npm packages that I've authored
view-cards
webpack-config-builders
compose-class-names
local-module-regex
mimic-webpack
simple-view
template-view
scss-node-resolve
ordered-collection-view
extendcompose
{
...,
ConversationSummary: {
component, // stateless component
wrapper, // composiiton of all wrappers
wrapped: ..., // wrapper(component)
// individual wrappers in case you want to pick and choose
redux,
redux_wrapped: redux(compoonent),
relay,
@antialias
antialias / vpn_connection.scpt
Last active April 8, 2020 00:14 — forked from adgedenkers/vpn_connection.scpt
Toggles VPN connectino. Stores your VPN password in the keychain.
#!/usr/bin/osascript
on run argv
tell application "System Events"
-- get current clipboard contents as a string
set CurrentClipboard to the clipboard as string
-- set the clipboad to your password
-- start playing with the VPN
tell current location of network preferences
@antialias
antialias / browserify-deps.js
Last active August 29, 2015 13:57
Using browserify's deps function to create a mapping between bundles and their dependencies.
var b = require('browserify')();
var dep2bundleSrcs = [];
b.add(modulePath);
b.deps().pipe(require('through')(function (dep) {
var fullPath = path.resolve(dep.id);
if (undefined === dep2bundleSrcs[fullPath]) {
dep2bundleSrcs[fullPath] = [];
console.log("adding bundle for dep", fullPath);
}
dep2bundleSrcs[fullPath].push(bundleMainScriptPath);