Str::wrap()
Wraps the string with the given string(s)
Str::wrap(string $string, string $before, string|null $after = null): string
Parameters
Name | Type | Default | Description |
---|---|---|---|
$stringrequired | string |
no default value | String to wrap |
$beforerequired | string |
no default value | String to prepend |
$after | string ornull |
null
|
String to append (if different from $before ) |
Return type
string