UNPKG

e-lado

Version:

[![CircleCI](https://circleci.com/gh/sharetribe/sharetribe/tree/master.svg?style=svg)](https://circleci.com/gh/sharetribe/sharetribe/tree/master) [![Dependency Status](https://gemnasium.com/sharetribe/sharetribe.png)](https://gemnasium.com/sharetribe/shar

26 lines (23 loc) 612 B
import * as actionTypes from '../constants/OnboardingConstants'; const initialState = { lastActionType: null, payload: { path: null, page: null, pathHistoryForward: true, }, }; export default function onboardingGuideReducer(state = initialState, action) { const { type, payload } = action; switch (type) { case actionTypes.ONBOARDING_GUIDE_PATH_UPDATE: return Object.assign({}, state, { lastActionType: type, path: payload.path, page: payload.page, pathHistoryForward: payload.pathHistoryForward, }); default: return state; } }