Search code examples
blogsstatic-sitepelican

In Pelican, how do I display the full latest article/post on the home page?


I'm using Pelican 4.2.0, and I'd like to always display the full text of my latest blog post on the 'home' page, then have other posts listed on a separate 'Articles' page. Is this a setting, a template configuration, or...?


Solution

  • Full-content versus summary display behavior is entirely managed in theme templates. The default notmyidea theme included with Pelican, for example, has an index.html template that shows the most recent full-content article at the top, followed by summaries of previous articles below. The relevant line that displays the full article content contains the following template variable:

    {{ article.content }}
    

    … whereas the line that shows article summaries instead uses the following template variable:

    {{ article.summary }}