string/consts.ts

/**
 * String tools.
 *
 * @module string
 * @license Apache-2.0
 * @copyright Mat. 2018-present
 */




/**
 * Return full set of ASCII letters.
 *
 * @function asciiLetters
 * @returns {String}
 */
export const asciiLetters = (): string =>
    "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";




/**
 * Return lowercase ASCII letters.
 *
 * @function asciiLowercase
 * @returns {String}
 */
export const asciiLowercase = (): string => "abcdefghijklmnopqrstuvwxyz";




/**
 * Return uppercase ASCII letters.
 *
 * @function asciiUppercase
 * @returns {String}
 */
export const asciiUppercase = (): string => "ABCDEFGHIJKLMNOPQRSTUVWXYZ";




/**
 * Return all digits.
 *
 * @function digits
 * @returns {String}
 */
export const digits = (): string => "0123456789";




/**
 * Construct empty string.
 *
 * @function empty
 * @returns {String}
 */
export const empty = (): string => "";




/**
 * Construct space.
 *
 * @function space
 * @returns {String}
 */
export const space = (): string => " ";




/**
 * Construct newline.
 *
 * @function nl
 * @returns {String}
 */
export const nl = (): string => "\n";




/**
 * Construct tab.
 *
 * @function tab
 * @returns {String}
 */
export const tab = (): string => "\t";