Created
August 12, 2019 05:51
-
-
Save richarddd/3d3264e87624f6f264cc7bfa63a58765 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
const counterStore = createStore( | |
{ | |
count: 0 | |
}, | |
{ | |
increment: ({ count }) => ({ count: count + 1 }), | |
decrement: ({ count }) => ({ count: count - 1 }) | |
} | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment