travel/admin/node_modules/yup/lib/util/makePath.js

18 lines
475 B
JavaScript
Raw Normal View History

2024-06-24 11:28:18 +08:00
"use strict";
exports.__esModule = true;
exports.default = makePath;
function makePath(strings) {
for (var _len = arguments.length, values = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
values[_key - 1] = arguments[_key];
}
var path = strings.reduce(function (str, next) {
var value = values.shift();
return str + (value == null ? '' : value) + next;
});
return path.replace(/^\./, '');
}
module.exports = exports["default"];