React Redux

export const exampleReducer = (state: State, action: Action) => {
  switch (action.type) {
    case 'SET_COUNT':
      return {
        ...state,
        count: action.payload
      };
    default:
      return state;
  }
};

ref

What Else?
inflearn react api server -50% 할인쿠폰: 15108-f2af1e086101 buy me a coffee