UNPKG

@shopgate/pwa-common-commerce

Version:

Commerce library for the Shopgate Connect PWA.

7 lines 586 B
import{RECEIVE_CATEGORY}from"../constants";/** * Dispatches the RECEIVE_CATEGORY action. * @param {string} categoryId The ID of the received category. * @param {Object} categoryData The data of the received category. * @param {Array} categoryChildren The children of received category. * @return {Object} The RECEIVE_CATEGORY action. */var receiveCategory=function receiveCategory(categoryId,categoryData,categoryChildren){return{type:RECEIVE_CATEGORY,categoryId:categoryId,categoryData:categoryData,categoryChildren:categoryChildren,products:[]};};export default receiveCategory;