import _objectSpread from "@babel/runtime/helpers/objectSpread2";
import { map, update } from 'lodash/fp';
import { typesWithElements } from '../utils';
export default function maybeSetElements(config) {
  var _elements$config;

  return typesWithElements.includes(config === null || config === void 0 ? void 0 : config.type) ? (_elements$config = _objectSpread({
    elements: []
  }, config), update('elements', map(maybeSetElements))(_elements$config)) : config;
}
//# sourceMappingURL=maybeSetElements.js.map