UNPKG

@dotup/dotup-ts-types

Version:
22 lines (21 loc) 626 B
import { IUrl } from "./Interfaces"; export declare function parseUrl(url: string): IUrl; /** * Replace placeholder in text with args * * Indexed: * const str = RegexTools.replace('{1} {0}', 'tool', 'Nice'}; * * With Object: * const str = RegexTools.replace('{a} {b}', {b: 'tool', a: 'Nice'}}; * */ export declare function replace(text: string, ...args: any[]): string; /** * Replace placeholder in text with args * * With Object: * const str = RegexTools.replacePath('{a} {b.1}', {b: {1:'tool'}, a: 'Nice'}}; * */ export declare function replacePath(text: string, values: object): string;