Make custom EJS listings bundled with extensions available without a template #11872
Replies: 2 comments 3 replies
-
Thanks! I had the same idea few months ago when I made an example of a gallery listings (https://github.com/mcanouil/quarto-issues-experiments/tree/main/test-gallery), but I forgot to open a feature request😅 Edit: published version of the listing at https://m.canouil.dev/quarto-issues-experiments/gallery/ |
Beta Was this translation helpful? Give feedback.
-
This would be lovely. Another use case for this (or more clarity on including assets) is quarto-gallery where I try/want to provide a Deno pre-render script and some minimal infra (a |
Beta Was this translation helpful? Give feedback.
-
Description
I recently made a Quarto extension that provides a custom listing.
When Lua filters are bundled with extensions, neither the filter's file extension nor its path (relative to either the project or the document) is required by the user. This means that the user does not need to know whether the extension is namespaced by an organisation. As long as the extension includes a
contributes.filters
entry, the user can specify the filter basename without an extension or path. It also means the that a filter used on several website pages can be installed just once in the project root without the user needing to juggle relative paths.As far as I'm aware, there isn't currently a similar registration mechanism for custom EJS listings. I currently advise my users to run
quarto use template
instead, so that the EJS file is copied from the extension repo into the document folder.It would be great if an extension could provide
contributes.listings
so that users could simplyquarto add
an extension to use the listing. I'm imagining the extension YAML would be something like:And then it could be used in a document in a website like:
Beta Was this translation helpful? Give feedback.
All reactions