Skip to content

Is it possible to make a blog with list of posts on frontpage #962

Description

@awalterschulze

I have only used medium and hugo before for creating a blog, but both have a home page (frontpage) with a list of the posts.
The current two examples in verso-templates both require a FrontPage, that does not contain the list of posts.

basic-blog:

def blog : Site := site Blog.FrontPage /
  "about" Blog.About
  "blog" Blog.Posts with
    Blog.Posts.FirstPost

blog-features:

def blog : Site := site Blog.FrontPage /
  static "static""static_files"
  "about" Blog.About
  "blog" Blog.Posts with
    Blog.Posts.Comparison
    Blog.Posts.FibIter
    Blog.Posts.Welcome
    Blog.Posts.FirstPost

I tried to create a site without a frontpage, so I could have the posts be the main page:

def blog : Site := site BlogSrc.Posts with
  BlogSrc.Posts.FirstPost

lake build succeeds, but lake exe generate-blog, gives the following error:

No remote data configuration specified, and the default file ./verso-sources.json does not exist.
Generating post ./2025-1-1-first-post
Blog BlogSrc.Posts.«the canonical document object name» not found in traverse pass!
An error was encountered!
make: *** [generate] Error 1

Is there another way to have the posts be on the first page the user sees?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions