Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

calculateCellWidthIndex.js 625B

1234567891011121314151617181920212223242526
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", {
  3. value: true
  4. });
  5. exports.default = void 0;
  6. var _stringWidth = _interopRequireDefault(require("string-width"));
  7. function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
  8. /**
  9. * Calculates width of each cell contents.
  10. *
  11. * @param {string[]} cells
  12. * @returns {number[]}
  13. */
  14. const calculateCellWidthIndex = cells => {
  15. return cells.map(value => {
  16. return (0, _stringWidth.default)(value);
  17. });
  18. };
  19. var _default = calculateCellWidthIndex;
  20. exports.default = _default;
  21. //# sourceMappingURL=calculateCellWidthIndex.js.map