UNPKG

choerodon-ui

Version:

An enterprise-class UI design language and React-based implementation

18 lines (16 loc) 581 B
import _objectSpread from "@babel/runtime/helpers/objectSpread2"; export default function createChains(newProps, oldProps) { var chains = {}; Object.keys(newProps).forEach(function (key) { var value = newProps[key]; var oldValue = oldProps[key]; if (typeof value === 'function' && typeof oldValue === 'function') { chains[key] = function () { value.apply(void 0, arguments); return oldValue.apply(void 0, arguments); }; } }); return _objectSpread(_objectSpread({}, newProps), chains); } //# sourceMappingURL=createChains.js.map