Skip to content
Snippets Groups Projects
GetTruncateContent 170 B
{{ $length := .length | default 150 }}

{{ $text := replace .text "<" " <" }}
{{ $text = chomp (truncate $length "…" (safeHTML (plainify $text))) }}
{{ return $text }}