Strings.stripStart()
Syntax
function stripStart(from: string, ...what: string[]): string
Returns a new string with all the specified tokens removed from the beginning of the string.
Parameters | |
from
|
The string to strip. |
what
Rest
|
The tokens to remove from the beginning of |
Example
import { Strings } from 'potence';
const string = 'nononoyesno';
Strings.stripStart(string, 'no'); // -> "yesno"
Remarks
Compare Strings.stripEnd()
.