hugo-universal-theme
hugo-universal-theme copied to clipboard
Sanitize blog summaries with plainify and truncate
Summary
- Applies
| plainify | truncateto.Summaryinrecent_posts.html(150 chars) andlist.html(300 chars) - Raw
.Summarycan emit HTML tags into card previews and list pages, breaking the layout with unclosed tags or unexpected markup plainifystrips HTML,truncateensures consistent card heights
Test plan
- [x] Create a blog post with rich HTML content (images, links, bold text, code blocks)
- [x] Verify the homepage "Recent Posts" section shows clean plain-text previews (no HTML leaking)
- [x] Verify the blog list page (
/blog/) also shows clean summaries
🤖 Generated with Claude Code