@teambit/component.instructions.exporting-components
Version:
54 lines (52 loc) • 3.9 kB
JavaScript
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = MDXContent;
var _react = _interopRequireDefault(require("react"));
var _react2 = require("@mdx-js/react");
var _excluded = ["components"]; // @ts-nocheck
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
/* @jsxRuntime classic */
/* @jsx mdx */
var layoutProps = {};
var MDXLayout = "wrapper";
function MDXContent(_ref) {
var components = _ref.components,
props = _objectWithoutProperties(_ref, _excluded);
return (0, _react2.mdx)(MDXLayout, _extends({}, layoutProps, props, {
components: components,
mdxType: "MDXLayout"
}), (0, _react2.mdx)("h2", null, "How to Version and Export Components"), (0, _react2.mdx)("blockquote", null, (0, _react2.mdx)("p", {
parentName: "blockquote"
}, "To export your components to the cloud so that they can be installed elsewhere you first have to tag and then export your components.")), (0, _react2.mdx)("p", null, "When we version or 'tag' a component, we commit changes and prepare it to be exported to a remote scope. This process most often includes compiling and testing, as well."), (0, _react2.mdx)("h3", null, "How to Tag a component"), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
parentName: "pre",
"className": "language-bash"
}, "bit tag <component-id> --patch --message \"this is the tag message\"\n")), (0, _react2.mdx)("h4", null, "How to Tag all components that have been modified"), (0, _react2.mdx)("p", null, "Tag all components and bump the patch number of each component version"), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
parentName: "pre",
"className": "language-bash"
}, "bit tag --all\n")), (0, _react2.mdx)("h3", null, "How to Export your Components"), (0, _react2.mdx)("p", null, "Once you have tagged your component you can then run the bit export command."), (0, _react2.mdx)("pre", null, (0, _react2.mdx)("code", {
parentName: "pre",
"className": "language-bash"
}, "bit export\n")), (0, _react2.mdx)("ul", null, (0, _react2.mdx)("li", {
parentName: "ul"
}, (0, _react2.mdx)("p", {
parentName: "li"
}, (0, _react2.mdx)("a", {
parentName: "p",
"href": "https://harmony-docs.bit.dev/building-with-bit/versioning-components"
}, "Learn more on Versioning Components"))), (0, _react2.mdx)("li", {
parentName: "ul"
}, (0, _react2.mdx)("p", {
parentName: "li"
}, (0, _react2.mdx)("a", {
parentName: "p",
"href": "https://harmony-docs.bit.dev/building-with-bit/exporting-components"
}, "Learn more on Exporting Components")))));
}
;
MDXContent.isMDXComponent = true;
//# sourceMappingURL=exporting-components.mdx.js.map
;