mirror of
https://github.com/danielstjules/Stringy.git
synced 2025-08-05 04:47:33 +02:00
Added documentation for stripWhitespace().
This commit is contained in:
11
README.md
11
README.md
@@ -79,6 +79,7 @@ s('string')->toTitleCase()->ensureRight('y') == 'Stringy'
|
|||||||
* [startsWith](#startswithstring-substring--boolean-casesensitive--true-)
|
* [startsWith](#startswithstring-substring--boolean-casesensitive--true-)
|
||||||
* [slice](#sliceint-start--int-end-)
|
* [slice](#sliceint-start--int-end-)
|
||||||
* [split](#splitstring-pattern--int-limit-)
|
* [split](#splitstring-pattern--int-limit-)
|
||||||
|
* [stripWhitespace](#stripwhitespace)
|
||||||
* [substr](#substrint-start--int-length-)
|
* [substr](#substrint-start--int-length-)
|
||||||
* [surround](#surroundstring-substring)
|
* [surround](#surroundstring-substring)
|
||||||
* [swapCase](#swapcase)
|
* [swapCase](#swapcase)
|
||||||
@@ -794,6 +795,16 @@ results.
|
|||||||
s('foo,bar,baz')->split(',', 2); // ['foo', 'bar']
|
s('foo,bar,baz')->split(',', 2); // ['foo', 'bar']
|
||||||
```
|
```
|
||||||
|
|
||||||
|
##### stripWhitespace()
|
||||||
|
|
||||||
|
Strip all whitespace characters. This includes tabs and newline
|
||||||
|
characters, as well as multibyte whitespace such as the thin space
|
||||||
|
and ideographic space.
|
||||||
|
|
||||||
|
```php
|
||||||
|
s(' Ο συγγραφέας ')->stripWhitespace(); // 'Οσυγγραφέας'
|
||||||
|
```
|
||||||
|
|
||||||
##### substr(int $start [, int $length ])
|
##### substr(int $start [, int $length ])
|
||||||
|
|
||||||
Returns the substring beginning at $start with the specified $length.
|
Returns the substring beginning at $start with the specified $length.
|
||||||
|
Reference in New Issue
Block a user