bit-bin
Version:
<a href="https://opensource.org/licenses/Apache-2.0"><img alt="apache" src="https://img.shields.io/badge/License-Apache%202.0-blue.svg"></a> <a href="https://github.com/teambit/bit/blob/master/CONTRIBUTING.md"><img alt="prs" src="https://img.shields.io/b
61 lines (44 loc) • 1.32 kB
JavaScript
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
function _bluebird() {
const data = require("bluebird");
_bluebird = function () {
return data;
};
return data;
}
function _scope() {
const data = require("../../../scope");
_scope = function () {
return data;
};
return data;
}
function _scopeComponentsImporter() {
const data = _interopRequireDefault(require("../../../scope/component-ops/scope-components-importer"));
_scopeComponentsImporter = function () {
return data;
};
return data;
}
var _default = /*#__PURE__*/function () {
var _modifyCIProps = (0, _bluebird().coroutine)(function* (id, ciProps, path) {
const scope = yield (0, _scope().loadScope)(path);
const bitId = yield scope.getParsedId(id);
const scopeComponentsImporter = _scopeComponentsImporter().default.getInstance(scope);
const component = yield scopeComponentsImporter.loadComponent(bitId);
return scope.sources.modifyCIProps({
source: component,
ciProps
});
});
function modifyCIProps(_x, _x2, _x3) {
return _modifyCIProps.apply(this, arguments);
}
return modifyCIProps;
}();
exports.default = _default;
;