@reliverse/rematch
Version:
@reliverse/rematch is a high-performance minimal glob matcher, with micromatch-level power, zepto-level size, and reliverse-grade dx.
127 lines (126 loc) • 3.7 kB
TypeScript
/**
* POSIX Bracket Regex
*/
declare const POSIX_REGEX_SOURCE: {
alnum: string;
alpha: string;
ascii: string;
blank: string;
cntrl: string;
digit: string;
graph: string;
lower: string;
print: string;
punct: string;
space: string;
upper: string;
word: string;
xdigit: string;
};
export declare const MAX_LENGTH: number;
export { POSIX_REGEX_SOURCE };
export declare const REGEX_BACKSLASH: RegExp;
export declare const REGEX_NON_SPECIAL_CHARS: RegExp;
export declare const REGEX_SPECIAL_CHARS: RegExp;
export declare const REGEX_SPECIAL_CHARS_BACKREF: RegExp;
export declare const REGEX_SPECIAL_CHARS_GLOBAL: RegExp;
export declare const REGEX_REMOVE_BACKSLASH: RegExp;
export declare const REPLACEMENTS: {
"***": string;
"**/**": string;
"**/**/**": string;
};
export declare const CHAR_0 = 48;
export declare const CHAR_9 = 57;
export declare const CHAR_UPPERCASE_A = 65;
export declare const CHAR_LOWERCASE_A = 97;
export declare const CHAR_UPPERCASE_Z = 90;
export declare const CHAR_LOWERCASE_Z = 122;
export declare const CHAR_LEFT_PARENTHESES = 40;
export declare const CHAR_RIGHT_PARENTHESES = 41;
export declare const CHAR_ASTERISK = 42;
export declare const CHAR_AMPERSAND = 38;
export declare const CHAR_AT = 64;
export declare const CHAR_BACKWARD_SLASH = 92;
export declare const CHAR_CARRIAGE_RETURN = 13;
export declare const CHAR_CIRCUMFLEX_ACCENT = 94;
export declare const CHAR_COLON = 58;
export declare const CHAR_COMMA = 44;
export declare const CHAR_DOT = 46;
export declare const CHAR_DOUBLE_QUOTE = 34;
export declare const CHAR_EQUAL = 61;
export declare const CHAR_EXCLAMATION_MARK = 33;
export declare const CHAR_FORM_FEED = 12;
export declare const CHAR_FORWARD_SLASH = 47;
export declare const CHAR_GRAVE_ACCENT = 96;
export declare const CHAR_HASH = 35;
export declare const CHAR_HYPHEN_MINUS = 45;
export declare const CHAR_LEFT_ANGLE_BRACKET = 60;
export declare const CHAR_LEFT_CURLY_BRACE = 123;
export declare const CHAR_LEFT_SQUARE_BRACKET = 91;
export declare const CHAR_LINE_FEED = 10;
export declare const CHAR_NO_BREAK_SPACE = 160;
export declare const CHAR_PERCENT = 37;
export declare const CHAR_PLUS = 43;
export declare const CHAR_QUESTION_MARK = 63;
export declare const CHAR_RIGHT_ANGLE_BRACKET = 62;
export declare const CHAR_RIGHT_CURLY_BRACE = 125;
export declare const CHAR_RIGHT_SQUARE_BRACKET = 93;
export declare const CHAR_SEMICOLON = 59;
export declare const CHAR_SINGLE_QUOTE = 39;
export declare const CHAR_SPACE = 32;
export declare const CHAR_TAB = 9;
export declare const CHAR_UNDERSCORE = 95;
export declare const CHAR_VERTICAL_LINE = 124;
export declare const CHAR_ZERO_WIDTH_NOBREAK_SPACE = 65279;
/**
* Create EXTGLOB_CHARS
*/
export declare function extglobChars(chars: any): {
"!": {
type: string;
open: string;
close: string;
};
"?": {
type: string;
open: string;
close: string;
};
"+": {
type: string;
open: string;
close: string;
};
"*": {
type: string;
open: string;
close: string;
};
"@": {
type: string;
open: string;
close: string;
};
};
/**
* Create GLOB_CHARS
*/
export declare function globChars(win32: any): {
DOT_LITERAL: string;
PLUS_LITERAL: string;
QMARK_LITERAL: string;
SLASH_LITERAL: string;
ONE_CHAR: string;
QMARK: string;
END_ANCHOR: string;
DOTS_SLASH: string;
NO_DOT: string;
NO_DOTS: string;
NO_DOT_SLASH: string;
NO_DOTS_SLASH: string;
QMARK_NO_DOT: string;
STAR: string;
START_ANCHOR: string;
SEP: string;
};