swc/crates/swc_bundler/tests/.cache/deno/60207da1f6086c99439bc3461ec7e13a91db0a5b.ts
2021-11-09 20:42:49 +09:00

16 lines
369 B
TypeScript

// Loaded from https://deno.land/x/segno@v1.1.0/lib/validations/isSurrogatePair.ts
// @ts-ignore allowing typedoc to build
import { assertString } from '../helpers/assertString.ts';
/**
* @ignore
*/
const surrogatePair = /[\uD800-\uDBFF][\uDC00-\uDFFF]/;
export const isSurrogatePair = (str: string) => {
assertString(str);
return surrogatePair.test(str);
};