UNPKG

633 BJavaScriptView Raw
1"use strict";
2var __importDefault = (this && this.__importDefault) || function (mod) {
3 return (mod && mod.__esModule) ? mod : { "default": mod };
4};
5Object.defineProperty(exports, "__esModule", { value: true });
6const partial_1 = __importDefault(require("lodash/partial"));
7function withProps(action, props) {
8 Object.freeze(props);
9 const actionWithProps = partial_1.default(action, partial_1.default.placeholder, props);
10 Object.defineProperty(actionWithProps, 'name', {
11 value: action.name || 'Anonymous',
12 });
13 return actionWithProps;
14}
15exports.default = withProps;
16//# sourceMappingURL=withProps.js.map
\No newline at end of file