-
-
Notifications
You must be signed in to change notification settings - Fork 14
Description
I've got a couple of extensions, TableauExcerptExtension and an as-yet-unpublished revisions tracking extension where I've got meta-content in frontmatter that should be written in the same format as the main content.
Right now, that only works reasonably well for markdown posts because Tableau.markdown/2 exists. However, if each post has a render_content/1 function included (similar to the renderer function attribute), this could be handled for extended content types without special handling‡.
Tableau.PostExtension.post() would need to be updated to include a render_content, function, and Tableau.Page.t() would need to be updated so the same function is exposed for use just like page.template.
This would allow post rendering to do something like this (Temple example in a index page):
div do
post.render_content.(post.excerpt)
end‡ There is special handling in an upcoming version of TableauExcerptExtension because it has to do some processing of the content, but that's something separate.