t-comm
Version:
专业、稳定、纯粹的工具库
18 lines (17 loc) • 361 B
TypeScript
/**
* 检查字符串长度
*
* @export
* @param {string} str 字符串
* @param {number} [num = 30] 长度
* @returns {boolean}
*
* @example
*
* checkStringLength('123', 2) // true
* checkStringLength('123', 3) // true
* checkStringLength('123', 4) // false
*
*
*/
export declare function checkStringLength(str?: string, num?: number): boolean;