posty.renderer.html module
- class posty.renderer.html.HtmlRenderer(site: Site, output_path: str = 'build')[source]
Bases:
RendererRenderer that outputs HTML files
- render_page(page: Page, template_name: str = 'page.html') None[source]
- Parameters:
page – a Page object
- render_post(post: Post, template_name: str = 'post.html') None[source]
- Parameters:
post – a Post object
- render_posts(posts: list[Post], prefix: str = '', template_name: str = 'posts.html') None[source]
Render a list of posts as sets of pages where each page has
num_posts_per_pageposts. Each page of posts will be rendered to the path page/:page/index.html relative to the Renderer output_pathIf
prefixis given, add that will be put in between the output_path and page path. For example if the prefix is ‘tags/foo/’ then a page path would look like ‘tags/foo/page/:page/index.html’