UNPKG

399 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3function wbr(options) {
4 let str = typeof options === 'string' ? options : options.fn(this);
5 str = str.replace(/([^_\-][_\-])([^_\-])/g, (m, a, b) => a + '<wbr>' + b);
6 str = str.replace(/([^A-Z])([A-Z][^A-Z])/g, (m, a, b) => a + '<wbr>' + b);
7 return str;
8}
9exports.wbr = wbr;
10//# sourceMappingURL=wbr.js.map
\No newline at end of file