Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@Porter97
Created April 27, 2020 20:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Porter97/bc73d7f25a1e702921c926cb229167bb to your computer and use it in GitHub Desktop.
Save Porter97/bc73d7f25a1e702921c926cb229167bb to your computer and use it in GitHub Desktop.
export default (state = {}, action) => {
switch(action.type) {
case 'COLLECTION_PAGE_LOADED':
return {
...state,
collection: action.payload.collection
};
case 'COLLECTION_PAGE_UNLOADED':
return {};
default:
return state;
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment