I'm creating a new blog using Jekyll.
On the main page, there will be a list of my 10 most recent posts.
The entries on this list will include a title, the post date, and an excerpt, most likely the first paragraph.
I'm only familiar with using Jekyll for basic templates, so I can either put only a variable in the page, or include the entire post.
Is there a way to somehow avoid using post.content
in the paginator, and only include up to a certain point in the post, which I define (e.g. ``{% endexcerpt %}`?
Something like {{ post.content | strip_html | truncatewords: 50 }}
produces a more consistent excerpt. It gets the first 50 words and strips any formatting.