StringExtension extension

on

Properties

capitalized String

Available on String?, provided by the StringExtension extension

Capitalizes the first letter of the string and makes the rest lowercase.
no setter
isBlank bool

Available on String?, provided by the StringExtension extension

Checks if the string is null, empty, or contains only whitespace.
no setter
onlyLatin String

Available on String?, provided by the StringExtension extension

Returns a new string containing only Latin alphabet characters (a-z, A-Z) and spaces.
no setter
reversed String?

Available on String?, provided by the StringExtension extension

Reverses the string.
no setter
wordCount int

Available on String?, provided by the StringExtension extension

Counts the number of words in the string, filtering out symbols and numbers.
no setter

Methods

getReadTime({int wordsPerMinute = 200}) int

Available on String?, provided by the StringExtension extension

Estimates the read time in minutes based on the word count.
hasMatch(String pattern) bool

Available on String?, provided by the StringExtension extension

Checks if the string matches the given regex pattern.
isAlphabetOnly() bool

Available on String?, provided by the StringExtension extension

Checks if the string contains only alphabetic characters.
isBool() bool

Available on String?, provided by the StringExtension extension

Checks if the string is a boolean value ('true' or 'false').
isNumericOnly() bool

Available on String?, provided by the StringExtension extension

Checks if the string contains only numeric characters.