prepend
The prepend() function adds one or more prefix strings before an input string and returns a new string.
Interactive example
Syntax
Classic signature
typescript
function prepend(
input: string,
...textsRest: string[]
): stringCurried signature
typescript
function prepend(
text: string
): (input: string) => stringParameters
input: The base string.text: Prefix used in curried mode.textsRest: One or more prefix strings to place beforeinput.
Return value
A new string built by concatenating all prefixes before the input string.
