UNPKG

everyutil

Version:

A comprehensive library of lightweight, reusable utility functions for JavaScript and TypeScript, designed to streamline common programming tasks such as string manipulation, array processing, date handling, and more.

14 lines (13 loc) 414 B
/** * Checks if a string is a valid hex color or byte string. * * Examples: * isHexString("#FF00AA") → true * isHexString("0xA9B4") → true * isHexString("hello") → false * * @author @dailker * @param {string} str - The string to check. * @returns {boolean} True if the string is a valid hex string, false otherwise. */ export declare function isHexString(str: string): boolean;