Created
March 27, 2018 06:38
-
-
Save factoryhr/04396665d84072b62ff1d498bc84dcde to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function incrementHandler(state, action) { | |
var nextState = Object.assign({}, state); | |
nextState.counter += 1; | |
return nextState; | |
} | |
function decrementHandler(state, action) { | |
var nextState = Object.assign({}, state); | |
nextState.counter -= 1; | |
return nextState; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment