getCompVarPrefix.js 375 B

12345678910
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = void 0;
  6. var getCompVarPrefix = function getCompVarPrefix(component, prefix) {
  7. return "".concat([prefix, component.replace(/([A-Z]+)([A-Z][a-z]+)/g, '$1-$2').replace(/([a-z])([A-Z])/g, '$1-$2')].filter(Boolean).join('-'));
  8. };
  9. var _default = exports.default = getCompVarPrefix;