Skip to content

Instantly share code, notes, and snippets.

@yelouafi
Last active August 29, 2015 14:26
Show Gist options
  • Save yelouafi/4ddec9b43ebec3c9377e to your computer and use it in GitHub Desktop.
Save yelouafi/4ddec9b43ebec3c9377e to your computer and use it in GitHub Desktop.
function update(count, action) {
return Action.case({
Increment : () => count + 1,
Decrement : () => count - 1
}, action);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment