🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

regexp-support

Package Overview
Dependencies
Maintainers
1
Versions
42
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

regexp-support - npm Package Compare versions

Comparing version

to
1.0.14

lib/pattern/cache/blocks.d.ts

514

index.d.ts

@@ -47,2 +47,3 @@ /**

lookBehindNegative: boolean;
dotUnicodeEmoji: boolean;
};

@@ -95,4 +96,515 @@ prototype: {

objectStringTag: string;
unicodeSet: {
unicode: Partial<{
White_Space: boolean;
Letter: boolean;
"ASCII": boolean;
"Alphabetic": boolean;
"Any": boolean;
"Default_Ignorable_Code_Point": boolean;
"Lowercase": boolean;
"Noncharacter_Code_Point": boolean;
"Uppercase": boolean;
"C": boolean;
"Other": boolean;
"Cc": boolean;
"Control": boolean;
"Cf": boolean;
"Format": boolean;
"Cn": boolean;
"Unassigned": boolean;
"Co": boolean;
"Private_Use": boolean;
"Cs": boolean;
"Surrogate": boolean;
"L": boolean;
"LC": boolean;
"Cased_Letter": boolean;
"Ll": boolean;
"Lowercase_Letter": boolean;
"Lm": boolean;
"Modifier_Letter": boolean;
"Lo": boolean;
"Other_Letter": boolean;
"Lt": boolean;
"Titlecase_Letter": boolean;
"Lu": boolean;
"Uppercase_Letter": boolean;
"M": boolean;
"Mark": boolean;
"Mc": boolean;
"Spacing_Mark": boolean;
"Me": boolean;
"Enclosing_Mark": boolean;
"Mn": boolean;
"Nonspacing_Mark": boolean;
"N": boolean;
"Number": boolean;
"Nd": boolean;
"Decimal_Number": boolean;
"Nl": boolean;
"Letter_Number": boolean;
"No": boolean;
"Other_Number": boolean;
"P": boolean;
"Punctuation": boolean;
"Pc": boolean;
"Connector_Punctuation": boolean;
"Pd": boolean;
"Dash_Punctuation": boolean;
"Pe": boolean;
"Close_Punctuation": boolean;
"Pf": boolean;
"Final_Punctuation": boolean;
"Pi": boolean;
"Initial_Punctuation": boolean;
"Po": boolean;
"Other_Punctuation": boolean;
"Ps": boolean;
"Open_Punctuation": boolean;
"S": boolean;
"Symbol": boolean;
"Sc": boolean;
"Currency_Symbol": boolean;
"Sk": boolean;
"Modifier_Symbol": boolean;
"Sm": boolean;
"Math_Symbol": boolean;
"So": boolean;
"Other_Symbol": boolean;
"Z": boolean;
"Separator": boolean;
"Zl": boolean;
"Line_Separator": boolean;
"Zp": boolean;
"Paragraph_Separator": boolean;
"Zs": boolean;
"Space_Separator": boolean;
"InAdlam": boolean;
"InAegean_Numbers": boolean;
"InAhom": boolean;
"InAlchemical_Symbols": boolean;
"InAlphabetic_Presentation_Forms": boolean;
"InAnatolian_Hieroglyphs": boolean;
"InAncient_Greek_Musical_Notation": boolean;
"InAncient_Greek_Numbers": boolean;
"InAncient_Symbols": boolean;
"InArabic": boolean;
"InArabic_Extended_A": boolean;
"InArabic_Mathematical_Alphabetic_Symbols": boolean;
"InArabic_Presentation_Forms_A": boolean;
"InArabic_Presentation_Forms_B": boolean;
"InArabic_Supplement": boolean;
"InArmenian": boolean;
"InArrows": boolean;
"InAvestan": boolean;
"InBalinese": boolean;
"InBamum": boolean;
"InBamum_Supplement": boolean;
"InBasic_Latin": boolean;
"InBassa_Vah": boolean;
"InBatak": boolean;
"InBengali": boolean;
"InBhaiksuki": boolean;
"InBlock_Elements": boolean;
"InBopomofo": boolean;
"InBopomofo_Extended": boolean;
"InBox_Drawing": boolean;
"InBrahmi": boolean;
"InBraille_Patterns": boolean;
"InBuginese": boolean;
"InBuhid": boolean;
"InByzantine_Musical_Symbols": boolean;
"InCJK_Compatibility": boolean;
"InCJK_Compatibility_Forms": boolean;
"InCJK_Compatibility_Ideographs": boolean;
"InCJK_Compatibility_Ideographs_Supplement": boolean;
"InCJK_Radicals_Supplement": boolean;
"InCJK_Strokes": boolean;
"InCJK_Symbols_And_Punctuation": boolean;
"InCJK_Unified_Ideographs": boolean;
"InCJK_Unified_Ideographs_Extension_A": boolean;
"InCJK_Unified_Ideographs_Extension_B": boolean;
"InCJK_Unified_Ideographs_Extension_C": boolean;
"InCJK_Unified_Ideographs_Extension_D": boolean;
"InCJK_Unified_Ideographs_Extension_E": boolean;
"InCJK_Unified_Ideographs_Extension_F": boolean;
"InCarian": boolean;
"InCaucasian_Albanian": boolean;
"InChakma": boolean;
"InCham": boolean;
"InCherokee": boolean;
"InCherokee_Supplement": boolean;
"InCombining_Diacritical_Marks": boolean;
"InCombining_Diacritical_Marks_Extended": boolean;
"InCombining_Diacritical_Marks_For_Symbols": boolean;
"InCombining_Diacritical_Marks_Supplement": boolean;
"InCombining_Half_Marks": boolean;
"InCommon_Indic_Number_Forms": boolean;
"InControl_Pictures": boolean;
"InCoptic": boolean;
"InCoptic_Epact_Numbers": boolean;
"InCounting_Rod_Numerals": boolean;
"InCuneiform": boolean;
"InCuneiform_Numbers_And_Punctuation": boolean;
"InCurrency_Symbols": boolean;
"InCypriot_Syllabary": boolean;
"InCyrillic": boolean;
"InCyrillic_Extended_A": boolean;
"InCyrillic_Extended_B": boolean;
"InCyrillic_Extended_C": boolean;
"InCyrillic_Supplement": boolean;
"InDeseret": boolean;
"InDevanagari": boolean;
"InDevanagari_Extended": boolean;
"InDingbats": boolean;
"InDomino_Tiles": boolean;
"InDuployan": boolean;
"InEarly_Dynastic_Cuneiform": boolean;
"InEgyptian_Hieroglyphs": boolean;
"InElbasan": boolean;
"InEmoticons": boolean;
"InEnclosed_Alphanumeric_Supplement": boolean;
"InEnclosed_Alphanumerics": boolean;
"InEnclosed_CJK_Letters_And_Months": boolean;
"InEnclosed_Ideographic_Supplement": boolean;
"InEthiopic": boolean;
"InEthiopic_Extended": boolean;
"InEthiopic_Extended_A": boolean;
"InEthiopic_Supplement": boolean;
"InGeneral_Punctuation": boolean;
"InGeometric_Shapes": boolean;
"InGeometric_Shapes_Extended": boolean;
"InGeorgian": boolean;
"InGeorgian_Supplement": boolean;
"InGlagolitic": boolean;
"InGlagolitic_Supplement": boolean;
"InGothic": boolean;
"InGrantha": boolean;
"InGreek_And_Coptic": boolean;
"InGreek_Extended": boolean;
"InGujarati": boolean;
"InGurmukhi": boolean;
"InHalfwidth_And_Fullwidth_Forms": boolean;
"InHangul_Compatibility_Jamo": boolean;
"InHangul_Jamo": boolean;
"InHangul_Jamo_Extended_A": boolean;
"InHangul_Jamo_Extended_B": boolean;
"InHangul_Syllables": boolean;
"InHanunoo": boolean;
"InHatran": boolean;
"InHebrew": boolean;
"InHigh_Private_Use_Surrogates": boolean;
"InHigh_Surrogates": boolean;
"InHiragana": boolean;
"InIPA_Extensions": boolean;
"InIdeographic_Description_Characters": boolean;
"InIdeographic_Symbols_And_Punctuation": boolean;
"InImperial_Aramaic": boolean;
"InInscriptional_Pahlavi": boolean;
"InInscriptional_Parthian": boolean;
"InJavanese": boolean;
"InKaithi": boolean;
"InKana_Extended_A": boolean;
"InKana_Supplement": boolean;
"InKanbun": boolean;
"InKangxi_Radicals": boolean;
"InKannada": boolean;
"InKatakana": boolean;
"InKatakana_Phonetic_Extensions": boolean;
"InKayah_Li": boolean;
"InKharoshthi": boolean;
"InKhmer": boolean;
"InKhmer_Symbols": boolean;
"InKhojki": boolean;
"InKhudawadi": boolean;
"InLao": boolean;
"InLatin_1_Supplement": boolean;
"InLatin_Extended_A": boolean;
"InLatin_Extended_Additional": boolean;
"InLatin_Extended_B": boolean;
"InLatin_Extended_C": boolean;
"InLatin_Extended_D": boolean;
"InLatin_Extended_E": boolean;
"InLepcha": boolean;
"InLetterlike_Symbols": boolean;
"InLimbu": boolean;
"InLinear_A": boolean;
"InLinear_B_Ideograms": boolean;
"InLinear_B_Syllabary": boolean;
"InLisu": boolean;
"InLow_Surrogates": boolean;
"InLycian": boolean;
"InLydian": boolean;
"InMahajani": boolean;
"InMahjong_Tiles": boolean;
"InMalayalam": boolean;
"InMandaic": boolean;
"InManichaean": boolean;
"InMarchen": boolean;
"InMasaram_Gondi": boolean;
"InMathematical_Alphanumeric_Symbols": boolean;
"InMathematical_Operators": boolean;
"InMeetei_Mayek": boolean;
"InMeetei_Mayek_Extensions": boolean;
"InMende_Kikakui": boolean;
"InMeroitic_Cursive": boolean;
"InMeroitic_Hieroglyphs": boolean;
"InMiao": boolean;
"InMiscellaneous_Mathematical_Symbols_A": boolean;
"InMiscellaneous_Mathematical_Symbols_B": boolean;
"InMiscellaneous_Symbols": boolean;
"InMiscellaneous_Symbols_And_Arrows": boolean;
"InMiscellaneous_Symbols_And_Pictographs": boolean;
"InMiscellaneous_Technical": boolean;
"InModi": boolean;
"InModifier_Tone_Letters": boolean;
"InMongolian": boolean;
"InMongolian_Supplement": boolean;
"InMro": boolean;
"InMultani": boolean;
"InMusical_Symbols": boolean;
"InMyanmar": boolean;
"InMyanmar_Extended_A": boolean;
"InMyanmar_Extended_B": boolean;
"InNKo": boolean;
"InNabataean": boolean;
"InNew_Tai_Lue": boolean;
"InNewa": boolean;
"InNumber_Forms": boolean;
"InNushu": boolean;
"InOgham": boolean;
"InOl_Chiki": boolean;
"InOld_Hungarian": boolean;
"InOld_Italic": boolean;
"InOld_North_Arabian": boolean;
"InOld_Permic": boolean;
"InOld_Persian": boolean;
"InOld_South_Arabian": boolean;
"InOld_Turkic": boolean;
"InOptical_Character_Recognition": boolean;
"InOriya": boolean;
"InOrnamental_Dingbats": boolean;
"InOsage": boolean;
"InOsmanya": boolean;
"InPahawh_Hmong": boolean;
"InPalmyrene": boolean;
"InPau_Cin_Hau": boolean;
"InPhags_Pa": boolean;
"InPhaistos_Disc": boolean;
"InPhoenician": boolean;
"InPhonetic_Extensions": boolean;
"InPhonetic_Extensions_Supplement": boolean;
"InPlaying_Cards": boolean;
"InPrivate_Use_Area": boolean;
"InPsalter_Pahlavi": boolean;
"InRejang": boolean;
"InRumi_Numeral_Symbols": boolean;
"InRunic": boolean;
"InSamaritan": boolean;
"InSaurashtra": boolean;
"InSharada": boolean;
"InShavian": boolean;
"InShorthand_Format_Controls": boolean;
"InSiddham": boolean;
"InSinhala": boolean;
"InSinhala_Archaic_Numbers": boolean;
"InSmall_Form_Variants": boolean;
"InSora_Sompeng": boolean;
"InSoyombo": boolean;
"InSpacing_Modifier_Letters": boolean;
"InSpecials": boolean;
"InSundanese": boolean;
"InSundanese_Supplement": boolean;
"InSuperscripts_And_Subscripts": boolean;
"InSupplemental_Arrows_A": boolean;
"InSupplemental_Arrows_B": boolean;
"InSupplemental_Arrows_C": boolean;
"InSupplemental_Mathematical_Operators": boolean;
"InSupplemental_Punctuation": boolean;
"InSupplemental_Symbols_And_Pictographs": boolean;
"InSupplementary_Private_Use_Area_A": boolean;
"InSupplementary_Private_Use_Area_B": boolean;
"InSutton_SignWriting": boolean;
"InSyloti_Nagri": boolean;
"InSyriac": boolean;
"InSyriac_Supplement": boolean;
"InTagalog": boolean;
"InTagbanwa": boolean;
"InTags": boolean;
"InTai_Le": boolean;
"InTai_Tham": boolean;
"InTai_Viet": boolean;
"InTai_Xuan_Jing_Symbols": boolean;
"InTakri": boolean;
"InTamil": boolean;
"InTangut": boolean;
"InTangut_Components": boolean;
"InTelugu": boolean;
"InThaana": boolean;
"InThai": boolean;
"InTibetan": boolean;
"InTifinagh": boolean;
"InTirhuta": boolean;
"InTransport_And_Map_Symbols": boolean;
"InUgaritic": boolean;
"InUnified_Canadian_Aboriginal_Syllabics": boolean;
"InUnified_Canadian_Aboriginal_Syllabics_Extended": boolean;
"InVai": boolean;
"InVariation_Selectors": boolean;
"InVariation_Selectors_Supplement": boolean;
"InVedic_Extensions": boolean;
"InVertical_Forms": boolean;
"InWarang_Citi": boolean;
"InYi_Radicals": boolean;
"InYi_Syllables": boolean;
"InYijing_Hexagram_Symbols": boolean;
"InZanabazar_Square": boolean;
}>;
script: Partial<{
"Adlam": boolean;
"Ahom": boolean;
"Anatolian_Hieroglyphs": boolean;
"Arabic": boolean;
"Armenian": boolean;
"Avestan": boolean;
"Balinese": boolean;
"Bamum": boolean;
"Bassa_Vah": boolean;
"Batak": boolean;
"Bengali": boolean;
"Bhaiksuki": boolean;
"Bopomofo": boolean;
"Brahmi": boolean;
"Braille": boolean;
"Buginese": boolean;
"Buhid": boolean;
"Canadian_Aboriginal": boolean;
"Carian": boolean;
"Caucasian_Albanian": boolean;
"Chakma": boolean;
"Cham": boolean;
"Cherokee": boolean;
"Common": boolean;
"Coptic": boolean;
"Cuneiform": boolean;
"Cypriot": boolean;
"Cyrillic": boolean;
"Deseret": boolean;
"Devanagari": boolean;
"Duployan": boolean;
"Egyptian_Hieroglyphs": boolean;
"Elbasan": boolean;
"Ethiopic": boolean;
"Georgian": boolean;
"Glagolitic": boolean;
"Gothic": boolean;
"Grantha": boolean;
"Greek": boolean;
"Gujarati": boolean;
"Gurmukhi": boolean;
"Han": boolean;
"Hangul": boolean;
"Hanunoo": boolean;
"Hatran": boolean;
"Hebrew": boolean;
"Hiragana": boolean;
"Imperial_Aramaic": boolean;
"Inherited": boolean;
"Inscriptional_Pahlavi": boolean;
"Inscriptional_Parthian": boolean;
"Javanese": boolean;
"Kaithi": boolean;
"Kannada": boolean;
"Katakana": boolean;
"Kayah_Li": boolean;
"Kharoshthi": boolean;
"Khmer": boolean;
"Khojki": boolean;
"Khudawadi": boolean;
"Lao": boolean;
"Latin": boolean;
"Lepcha": boolean;
"Limbu": boolean;
"Linear_A": boolean;
"Linear_B": boolean;
"Lisu": boolean;
"Lycian": boolean;
"Lydian": boolean;
"Mahajani": boolean;
"Malayalam": boolean;
"Mandaic": boolean;
"Manichaean": boolean;
"Marchen": boolean;
"Masaram_Gondi": boolean;
"Meetei_Mayek": boolean;
"Mende_Kikakui": boolean;
"Meroitic_Cursive": boolean;
"Meroitic_Hieroglyphs": boolean;
"Miao": boolean;
"Modi": boolean;
"Mongolian": boolean;
"Mro": boolean;
"Multani": boolean;
"Myanmar": boolean;
"Nabataean": boolean;
"New_Tai_Lue": boolean;
"Newa": boolean;
"Nko": boolean;
"Nushu": boolean;
"Ogham": boolean;
"Ol_Chiki": boolean;
"Old_Hungarian": boolean;
"Old_Italic": boolean;
"Old_North_Arabian": boolean;
"Old_Permic": boolean;
"Old_Persian": boolean;
"Old_South_Arabian": boolean;
"Old_Turkic": boolean;
"Oriya": boolean;
"Osage": boolean;
"Osmanya": boolean;
"Pahawh_Hmong": boolean;
"Palmyrene": boolean;
"Pau_Cin_Hau": boolean;
"Phags_Pa": boolean;
"Phoenician": boolean;
"Psalter_Pahlavi": boolean;
"Rejang": boolean;
"Runic": boolean;
"Samaritan": boolean;
"Saurashtra": boolean;
"Sharada": boolean;
"Shavian": boolean;
"Siddham": boolean;
"SignWriting": boolean;
"Sinhala": boolean;
"Sora_Sompeng": boolean;
"Soyombo": boolean;
"Sundanese": boolean;
"Syloti_Nagri": boolean;
"Syriac": boolean;
"Tagalog": boolean;
"Tagbanwa": boolean;
"Tai_Le": boolean;
"Tai_Tham": boolean;
"Tai_Viet": boolean;
"Takri": boolean;
"Tamil": boolean;
"Tangut": boolean;
"Telugu": boolean;
"Thaana": boolean;
"Thai": boolean;
"Tibetan": boolean;
"Tifinagh": boolean;
"Tirhuta": boolean;
"Ugaritic": boolean;
"Vai": boolean;
"Warang_Citi": boolean;
"Yi": boolean;
"Zanabazar_Square": boolean;
}>;
};
}>;
export import FlagsName = FlagsName;
export { FlagsName };
export { hasSupportFlag };

@@ -99,0 +611,0 @@ export { testFlag };

@@ -10,8 +10,16 @@ "use strict";

const flags_1 = require("./lib/flags");
exports.FlagsName = flags_1.FlagsName;
const index_1 = require("./lib/index");
const pattern_1 = require("./lib/pattern");
exports.testPattern = pattern_1.testPattern;
const unicode_1 = require("./lib/pattern/charset/unicode");
const unicode_script_1 = require("./lib/pattern/charset/unicode-script");
const prototype_1 = require("./lib/proto/prototype");
const static_1 = require("./lib/proto/static");
const symbol_1 = require("./lib/symbol");
/**
* @link https://zh.wikipedia.org/wiki/%E6%AD%A3%E5%88%99%E8%A1%A8%E8%BE%BE%E5%BC%8F
* @link https://www.regular-expressions.info/posixbrackets.html
* @link http://2ality.com/archive.html?tag=regexp
*/
const _support = {

@@ -54,2 +62,22 @@ nativeFlags: '',

objectStringTag: Object.prototype.toString.call(/a/),
unicodeSet: (() => {
return {
//unicodeKeys: Object.keys(UNICODE_ALL),
//scriptKeys: Object.keys(UNICODE_SCRIPTS_ALL),
unicode: Object.entries(unicode_1.testUnicodeAll())
.reduce(function (a, b) {
if (b[1] !== null) {
a[b[0]] = b[1];
}
return a;
}, {}),
script: Object.entries(unicode_script_1.testUnicodeScriptAll())
.reduce(function (a, b) {
if (b[1] !== null) {
a[b[0]] = b[1];
}
return a;
}, {}),
};
})(),
};

@@ -66,3 +94,2 @@ _support.nativeFlags = Object

exports.support = Object.freeze(_support);
exports.FlagsName = flags_1.FlagsName;
exports.default = exports.support;

@@ -9,2 +9,4 @@ /**

import libPattern, { PatternSupport, testPattern, IPatternTestFn, IPatternTestRow } from './lib/pattern';
import { testUnicodeAll, UNICODE_ALL } from './lib/pattern/charset/unicode';
import { testUnicodeScriptAll, UNICODE_SCRIPTS_ALL } from './lib/pattern/charset/unicode-script';
import { testPrototype, IRegExpPrototype } from './lib/proto/prototype';

@@ -14,2 +16,7 @@ import { testStatic, IRegExpStatic } from './lib/proto/static';

/**
* @link https://zh.wikipedia.org/wiki/%E6%AD%A3%E5%88%99%E8%A1%A8%E8%BE%BE%E5%BC%8F
* @link https://www.regular-expressions.info/posixbrackets.html
* @link http://2ality.com/archive.html?tag=regexp
*/
const _support = {

@@ -71,2 +78,36 @@

objectStringTag: Object.prototype.toString.call(/a/) as string,
unicodeSet: (() => {
return {
//unicodeKeys: Object.keys(UNICODE_ALL),
//scriptKeys: Object.keys(UNICODE_SCRIPTS_ALL),
unicode: Object.entries(testUnicodeAll())
.reduce(function (a, b)
{
if (b[1] !== null)
{
a[b[0]] = b[1];
}
return a;
}, {} as Partial<ReturnType<typeof testUnicodeAll>>),
script: Object.entries(testUnicodeScriptAll())
.reduce(function (a, b)
{
if (b[1] !== null)
{
a[b[0]] = b[1];
}
return a;
}, {} as Partial<ReturnType<typeof testUnicodeScriptAll>>),
};
})(),
};

@@ -90,4 +131,3 @@

export import FlagsName = FlagsName
export { FlagsName }
export { hasSupportFlag };

@@ -94,0 +134,0 @@ export { testFlag };

@@ -15,2 +15,3 @@ /**

lookBehindNegative: boolean;
dotUnicodeEmoji: boolean;
};

@@ -17,0 +18,0 @@ export declare const PatternTest: {

@@ -17,2 +17,3 @@ "use strict";

lookBehindNegative: false,
dotUnicodeEmoji: false,
};

@@ -63,2 +64,5 @@ exports.PatternTest = {

],
dotUnicodeEmoji: [
['^.$', 'u', '😀', true, 'test'],
],
};

@@ -65,0 +69,0 @@ // @ts-ignore

@@ -20,2 +20,4 @@ /**

lookBehindNegative: false,
dotUnicodeEmoji: false,
};

@@ -77,2 +79,8 @@

],
dotUnicodeEmoji: [
['^.$', 'u', '😀', true, 'test'],
],
};

@@ -79,0 +87,0 @@

{
"name": "regexp-support",
"version": "1.0.13",
"version": "1.0.14",
"description": "check RegExp ( regular expressions ) support",

@@ -42,3 +42,10 @@ "keywords": [

"test": "echo \"Error: no test specified\" && exit 1"
},
"dependencies": {},
"devDependencies": {
"@types/fs-extra": "^5.0.2",
"fs-extra": "^6.0.0",
"globby": "^8.0.1",
"xregexp": "^4.1.1"
}
}

@@ -37,2 +37,6 @@ # regexp-support

## todo
* need more test on unicode set [unicode.ts](lib/pattern/charset/unicode.ts) , [unicode-script.ts](lib/pattern/charset/unicode-script.ts)
### desc

@@ -39,0 +43,0 @@

lib/posix.d.ts