/*
 *
 * {{ properCase name }} reducer
 *
 */
import produce from 'immer'
import { createActions } from 'reduxsauce'

export const initialState = {
  somePayLoad: null
}

export const { Types: {{ camelCase name }}Types, Creators: {{ camelCase name }}Creators } = createActions({
  defaultAction: ['somePayLoad']
})

export const {{ camelCase name }}Reducer = (state = initialState, action) =>
  produce(state, draft => {
    switch (action.type) {
      case {{ camelCase name}}Types.DEFAULT_ACTION:
        draft.somePayLoad = action.somePayLoad;
      default:
    }
  })

export default {{ camelCase name }}Reducer
