widont($text)

Avoids typographical widows in strings by replacing the last space with  

  • $text (string)
  • return (string)

Example

<?= widont($page->title()) ?>