Skip to content

Commit 07cb4aa

Browse files
committed
updated README.md
1 parent 0b742fc commit 07cb4aa

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -702,6 +702,27 @@ S(' 1 2 3--__--4 5 6-7__8__9--0').strip(' ', '_', '-').s; //'1234567890'
702702
S('can words also be stripped out?').strip('words', 'also', 'be').s; //'can stripped out?'
703703
```
704704

705+
### - stripLeft([chars]) ###
706+
Returns a new string in which all chars have been stripped from the beginning of the string (default whitespace characters).
707+
708+
Example:
709+
710+
```javascript
711+
S(' hello ').stripLeft().s; //'hello '
712+
S('abcz').stripLeft('a-z').s; //'bcz'
713+
S('www.example.com').stripLeft('w.').s; //'example.com'
714+
```
715+
716+
### - stripRight([chars]) ###
717+
Returns a new string in which all chars have been stripped from the end of the string (default whitespace characters).
718+
719+
Example:
720+
721+
```javascript
722+
S(' hello ').stripRight().s; //' hello'
723+
S('abcz').stripRight('a-z').s; //'abc'
724+
```
725+
705726

706727
### - stripPunctuation()
707728

0 commit comments

Comments
 (0)