Skip to content

isString

Functions to check the type of value if it's primitive or object string.

isString function

ts
function isString(value?: unknown): boolean

Checks if value is classified as a primitive string.

Parameters

  • value?: unknown The value to check.

Return boolean

true if value is a string, otherwise false.

isStringObject function

ts
function isStringObject(value?: unknown): boolean

Checks if value is classified as a String primitive or object.

Parameters

  • value?: unknown The value to check.

Return boolean

true if value is a string or String object, otherwise false.

MIT License, Made with ❤️