File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -177,6 +177,8 @@ There is also a method to get the bytes stored at some position::
177
177
b('नमस्ते')->bytesAt(1); // [164]
178
178
u('नमस्ते')->bytesAt(1); // [224, 164, 174]
179
179
180
+ .. _methods-related-to-length-and-white-spaces :
181
+
180
182
Methods Related to Length and Whitespace Characters
181
183
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
182
184
@@ -207,9 +209,9 @@ Methods Related to Length and Whitespace Characters
207
209
u(' ')->isEmpty(); // false
208
210
u('')->isEmpty(); // true
209
211
210
- // removes all whitespace from the start and end of the string and replaces two
211
- // or more consecutive whitespace characters inside contents by a single white space
212
- u(" \n\n hello world \n \n")->collapseWhitespace(); // 'hello world'
212
+ // removes all whitespace (' \n\r\t\x0C') from the start and end of the string and
213
+ // replaces two or more consecutive whitespace characters with a single space (' ') character
214
+ u(" \n\n hello \t \n\r world \n \n")->collapseWhitespace(); // 'hello world'
213
215
214
216
Methods to Change Case
215
217
~~~~~~~~~~~~~~~~~~~~~~
You can’t perform that action at this time.
0 commit comments