Returns a string with whitespace removed from the start and end of the string. Supports the removal of unicode whitespace.
string: " This is so sloppy "
{{ string | trim }}
{{ Statamic::modify($string)->trim() }}
This is so sloppy
trim
ModifierReturns a string with whitespace removed from the start and end of the string. Supports the removal of unicode whitespace.
string: " This is so sloppy "
{{ string | trim }}
{{ Statamic::modify($string)->trim() }}
This is so sloppy
Submit improvements, related content, or suggestions through Github.
Betterify this page →