How to use the unescapeHTML function from underscore.string
Find comprehensive JavaScript underscore.string.unescapeHTML code examples handpicked from public code repositorys.
GitHub: PastVu/pastvu
388 389 390 391 392 393 394 395 396 397 398 399 400
let result = txt; result = result.replace(/<br\s*[/]?>/gi, brShrink ? ' ' : '\n'); // Заменяем <br> на \n или ничего result = _s.stripTags(result); // Убираем обрамляющие тэги ahref result = _s.unescapeHTML(result); // Возвращаем эскейпленные return result; }; Utils.txtdiff = (function () {
14
70
0
+ 6 other calls in file
37 38 39 40 41 42 43 44 45 46 47 48
exports.escapeHTML = function(value, options, callback){ callback(null, str.escapeHTML(String(value))); }; exports.unescapeHTML = function(value, options, callback){ callback(null, str.unescapeHTML(String(value))); }; exports.titleize = function(value, options, callback){ callback(null, str.titleize(String(value)));
2
2
0
+ 2 other calls in file
underscore.string.slugify is the most popular function in underscore.string (323 examples)