isBlank
isBlank(str: string): booleanSource: string.ts:194
Checks if a string is empty or contains only whitespace
Parameters
str(string) — The input string
Returns
boolean— True if string is empty or whitespace only
Example
CODE
isBlank('') // true
isBlank(' ') // true
isBlank('hello') // false
isBlank(' hi ') // false