mirror of
https://github.com/pdemian/human2regex.git
synced 2025-05-16 04:20:35 -07:00
17 lines
541 B
TypeScript
17 lines
541 B
TypeScript
/*! Copyright (c) 2020 Patrick Demian; Licensed under MIT */
|
|
/**
|
|
* Minimizes the match string by finding duplicates or substrings in the array
|
|
*
|
|
* @param arr the array of matches
|
|
* @internal
|
|
*/
|
|
export declare function minimizeMatchString(arr: string[]): string;
|
|
/**
|
|
* Groups a regex fragment if it needs to be grouped
|
|
*
|
|
* @param fragment fragment of regular expression to potentially group
|
|
* @returns a non-capturing group if there needs to be one
|
|
* @internal
|
|
*/
|
|
export declare function groupIfRequired(fragment: string): string;
|