Files: 4cb19feb19f09ec24e9ab9ee78c7df9337ce2f68 / app / reducers / todos.js
234 bytesRaw
1 | module.exports = todos |
2 | |
3 | function todos (state = {}, action) { |
4 | switch (action.type) { |
5 | case 'CREATE_TODO': |
6 | return { |
7 | ...state, |
8 | [action.payload.id]: action.payload |
9 | } |
10 | default: |
11 | return state |
12 | } |
13 | } |
14 |
Built with git-ssb-web