Sha256: f91c2c26c401b1bd9f68b85a0ae4854be056f0d116de528d879fd9bdabdf11ef
Contents?: true
Size: 511 Bytes
Versions: 36
Compression:
Stored size: 511 Bytes
Contents
"use strict"; exports.__esModule = true; exports.default = unesc; var HEX_ESC = /\\(?:([0-9a-fA-F]{6})|([0-9a-fA-F]{1,5})(?: |(?![0-9a-fA-F])))/g; var OTHER_ESC = /\\(.)/g; function unesc(str) { str = str.replace(HEX_ESC, function (_, hex1, hex2) { var hex = hex1 || hex2; var code = parseInt(hex, 16); return String.fromCharCode(code); }); str = str.replace(OTHER_ESC, function (_, char) { return char; }); return str; } module.exports = exports["default"];
Version data entries
36 entries across 35 versions & 9 rubygems