summaryrefslogtreecommitdiff
path: root/bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js
diff options
context:
space:
mode:
Diffstat (limited to 'bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js')
-rw-r--r--bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js26
1 files changed, 26 insertions, 0 deletions
diff --git a/bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js b/bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js
new file mode 100644
index 00000000..cb6ca15f
--- /dev/null
+++ b/bin/wiki/ImportarDesdeURL/node_modules/lodash/_hasUnicode.js
@@ -0,0 +1,26 @@
+/** Used to compose unicode character classes. */
+var rsAstralRange = '\\ud800-\\udfff',
+ rsComboMarksRange = '\\u0300-\\u036f',
+ reComboHalfMarksRange = '\\ufe20-\\ufe2f',
+ rsComboSymbolsRange = '\\u20d0-\\u20ff',
+ rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,
+ rsVarRange = '\\ufe0e\\ufe0f';
+
+/** Used to compose unicode capture groups. */
+var rsZWJ = '\\u200d';
+
+/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */
+var reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');
+
+/**
+ * Checks if `string` contains Unicode symbols.
+ *
+ * @private
+ * @param {string} string The string to inspect.
+ * @returns {boolean} Returns `true` if a symbol is found, else `false`.
+ */
+function hasUnicode(string) {
+ return reHasUnicode.test(string);
+}
+
+module.exports = hasUnicode;