UNPKG
@ka1do/kit
Version:
latest (0.0.3)
0.0.3
Kaido Kit
github.com/kaido-team/kaido-kit
kaido-team/kaido-kit
@ka1do/kit
/
helpers
/
node_modules
/
astral-regex
/
index.js
7 lines
(4 loc)
•
203 B
JavaScript
View Raw
1
2
3
4
5
6
7
'use strict'
;
const
regex =
'[\uD800-\uDBFF][\uDC00-\uDFFF]'
;
const
astralRegex
= options => options && options.
exact
?
new
RegExp
(
`^
${regex}
$`
) :
new
RegExp
(regex,
'g'
);
module
.
exports
= astralRegex;