scriptorium/rendering/views/base
Types
The base view pre-renders some content once, so that it can be reused for every render.
pub type PreRendered {
PreRendered(tags: Element(Nil), archives: Element(Nil))
}
Constructors
-
PreRendered(tags: Element(Nil), archives: Element(Nil))
Functions
pub fn generate(
db: Database,
config: Configuration,
) -> fn(Element(Nil), List(Element(Nil)), String) -> Element(Nil)
pub fn pre_render(
db: Database,
config: Configuration,
tags: fn(Database, Configuration) -> Element(Nil),
archives: fn(Database, Configuration) -> Element(Nil),
) -> PreRendered
Pre-render the tag and archive elements using the given tags and archives components.