UNPKG

@wordpress/wordcount

Version:
21 lines (19 loc) 586 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = transposeHTMLEntitiesToCountableChars; /** * Internal dependencies */ /** * Replaces items matched in the regex with a single character. * * @param settings The main settings object containing regular expressions * @param text The string being counted. * @return The manipulated text. */ function transposeHTMLEntitiesToCountableChars(settings, text) { return text.replace(settings.HTMLEntityRegExp, 'a'); } //# sourceMappingURL=transposeHTMLEntitiesToCountableChars.js.map