Skip to main content

isValidString

talawa-apiDocs


talawa-api / libraries/validators/validateString / isValidString

Function: isValidString()

> isValidString(str, maxLength): object

Checks if a given string is less than a specified maximum length.

Parameters

str: string

The string to check.

maxLength: number

The maximum allowed length of the string.

Returns

object

An object containing a boolean indicating if the string is less than the maximum length.

isLessThanMaxLength

> isLessThanMaxLength: boolean

Defined in

src/libraries/validators/validateString.ts:8