Issue with markdonify with truncate

I use the following code in my front page:

<div class="hero">
    <a href="{{ .Permalink }}"><h2 class="txtcenter">{{ .Title}}</h2></a>
    <h3 class="txtcenter txtgrey">{{ .Description }}</h3>
    <p>{{ .Summary | markdownify | truncate 700 }}<a href="{{ .Permalink }}">{{- partial "icons" "next" . -}}</a></p>

But it looks like the markdownify doesn’t work when truncated. It’s fine when the full content is displayed but not on the front page when truncated.
Am i missing something ?

.Summary strips out HTML. You can use .Content because you’re truncating it anyway.

Thank you.
It works fine with .Content

1 Like