Actions/counter.actions.jsReducers/counter.reducer.jsActions/counter.actions.jsimport { createAction } from‘redux-actions’ // export const increment = () => ({ type: ‘increment’ }) // export const decrement = () => ({ type: ‘decrement’ }) export const increment_action = createAction(‘increment’) export const decrement_action = createAction(‘decrement’) Reducers/counter.reducer.jsimport { handleActions as createReducer } from‘redux-actions’ import { increment_action, decrement_action } from‘../Actions/counter.actions’ const initialState = { count:10 } const counterReducer = createReducer({ [increment_action]: (state, action) => ({ count:state.count + 1 }), [decrement_action]: (state, action) => ({ count:state.count - 1 }), }, initialState) export default counterReducer