Created
April 8, 2019 20:38
-
-
Save rocksinghajay/0d712772b753d4e888dae71f91e8b195 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
import SET_TEXT from '../types/types' | |
const initialState = { | |
text: '', | |
} | |
const dummyReducer = (state = initialState, action = {}) => { | |
switch(action.type) { | |
case SET_TEXT: | |
return { ...state, text: action.payload.data } | |
default: | |
return state; | |
} | |
} | |
export default dummyReducer |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment