@technobuddha > library > String
Operations
| Name | Type | Description |
|---|---|---|
| clean | Function | Remove all occurrences of characters from the beginning and end of the string |
| cleanEnd | Function | Remove all occurrences of characters from the end of the string |
| cleanStart | Function | Remove all occurrences of characters from the start of the string |
| collapseBreakingSpace | Function | Replace all breaking space (space, tab, carriage return, new line) with a single space |
| CollapseBreakingSpaceOptions | Type | Options for the collapseBreakingSpace function |
| collapseWhitespace | Function | Replace all whitespace within a string with a single space |
| CollapseWhitespaceOptions | Type | Options for the collapseWhitespace function |
| correctMSWord | Function | Correct character sequences that Microsoft Word changes to make it look prettier |
| count | Function | Compute the number of times a substring occurs within a string |
| CountOptions | Type | Options for the count function |
| FilenameOptions | Type | Options for the toFilename function |
| fillTemplate | Function | Fill a template with supplied values |
| FillTemplateOptions | Type | Options for the fillTemplate function |
| indent | Function | Indent each line of a string |
| IndentOptions | Type | Options for the indentation functions: getIndent, indent, and unindent |
| initials | Function | Returns the uppercase initials of the given string. |
| mask | Function | Use a simple mask to display a string |
| MaskOptions | Type | Options for the mask function |
| numberToLetter | Function | Convert a number to a letter, using the alphabet (default: A-Z) |
| NumberToLetterOptions | Type | Options for the numberToLetter function |
| singleLine | Function | Joins a template literal into a single line string by removing line breaks and leading whitespace, then interleaving the provided arguments. The result is a trimmed, single-line string. |
| sortOrder | Function | Convert a string into a sortable string |
| SortOrderOptions | Type | Options for the sortOrder function |
| strip | Function | Removes unwanted sequences from the input string. |
| StripOptions | Type | Options for stripping unwanted characters or sequences from strings. |
| toASCII | Function | Change a string to be all from the basic latin unicode plane |
| toEnumeration | Function | Convert a string to a numeric value |
| toFilename | Function | Convert a string so that it can be used as a filename |
| unindent | Function | Remove indentation from text |
| wordwrap | Function | Wrap text so that it fits within a area of fixed width |
| WordwrapOptions | Type | Options for the wordwrap function |