Urara-Blog/node_modules/.pnpm-store/v3/files/8a/41ce6c73bb10c68fc6f7ce82950266e35d04ead009d3f9a64bd0620cbf5b55255daf74ca19a8ac0d92b8ad5fd545b8e177dd0190f4cfeb90be510e5d71ddb0
2022-08-14 01:14:53 +08:00

14 lines
471 B
Text

/**
* @author Toru Nagashima <https://github.com/mysticatea>
*/
"use strict";
/**
* Check whether given two characters are a surrogate pair.
* @param {number} lead The code of the lead character.
* @param {number} tail The code of the tail character.
* @returns {boolean} `true` if the character pair is a surrogate pair.
*/
module.exports = function isSurrogatePair(lead, tail) {
return lead >= 0xD800 && lead < 0xDC00 && tail >= 0xDC00 && tail < 0xE000;
};