@shopgate/pwa-common
Version:
Common library for the Shopgate Connect PWA.
4 lines • 706 B
JavaScript
function _extends(){_extends=Object.assign||function(target){for(var i=1;i<arguments.length;i++){var source=arguments[i];for(var key in source){if(Object.prototype.hasOwnProperty.call(source,key)){target[key]=source[key];}}}return target;};return _extends.apply(this,arguments);}import{connect}from'react-redux';import _showModal from'@shopgate/pwa-common/actions/modal/showModal';/**
* @param {Function} dispatch The redux dispatch function
* @return {Object}
*/var mapDispatchToProps=function mapDispatchToProps(dispatch){return{showModal:function showModal(options){return dispatch(_showModal(_extends({confirm:'modal.ok',dismiss:null},options)));}};};export default connect(null,mapDispatchToProps);