Skip to content

Instantly share code, notes, and snippets.

View jimbolla's full-sized avatar

Jim Bolla jimbolla

View GitHub Profile
@jimbolla
jimbolla / cloudSettings
Last active October 22, 2018 02:45
Visual Studio Code Sync Settings GIST
{"lastUpload":"2018-10-22T02:45:49.253Z","extensionVersion":"v3.2.0"}
{
// See http://go.microsoft.com/fwlink/?LinkId=827846
// for the documentation about the extensions.json format
"recommendations": [
// ESLint
"dbaeumer.vscode-eslint",
// Flow Language Support
"flowtype.flow-for-vscode",
@jimbolla
jimbolla / withStore.js
Last active September 10, 2016 14:54
withStore
import hoistStatics from 'hoist-non-react-statics'
import invariant from 'invariant'
import { Component, PropTypes, createElement } from 'react'
export default function withStore(
{
getDisplayName = name => `WithStore(${name})`,
methodName = 'withStore',
storeKey = 'store',
withRef = false,
@jimbolla
jimbolla / package.json
Last active April 27, 2016 15:11
React 15 - IE11 autofill bug demo
{
"name": "react-test",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"author": "",
"license": "ISC",
@jimbolla
jimbolla / protectFromUnmount.js
Created November 16, 2015 19:38
protectFromUnmount
function protectFromUnmount() {
let callbacks = {};
let count = 0;
const noop = value => value;
const wrapCallback = id => function(...params) {
const raceSafeCallbacks = callbacks;
if (!raceSafeCallbacks)