-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Accessing quarto metadata programmatically via QuartoNotebookWorker #139
Comments
Stored in
|
Yes, although there's currently no open way to access anything QNW-related, is there? The extension methods hook in at package load time, you couldn't easily reach that from the notebook itself. And I think we were holding off on adding any API into the notebook workspace due to it not being available in a REPL. |
Would only be accessed in 3rd-parth package extensions, not directly in a notebook, e.g. module PackageNameQuartoNotebookWorkerExt
import PackageName
import QuartoNotebookWorker
function QuartoNotebookWorker.expand(::PackageName.Foo)
opts = QuartoNotebookWorker.options() # hypothetical public API, used at runtime.
# ...
end
end |
Right, ok, so it should stay that way then. One could not develop such functionality directly within notebooks is the only drawback I can see. |
Nope, you can't. |
Yes for "serious" development that's true, it just adds overhead if you want to quickly try out things. I would have liked an "escape hatch" of some kind. Actually, maybe that's already possible by requiring the right UUID manually. Just thinking out loud here, I think the extension is in general the right place to do this kind of stuff. |
Given the way the |
Now that we have the
expand
extension pipeline, I was thinking that downstream packages might want to expand differently depending on, for example, the output format that quarto renders to. I think that's different from the loading hooks we currently have. So I wonder how we could make the full quarto metadata accessible, like you can access it from knitr withknitr::pandoc_to()
, as one example.The text was updated successfully, but these errors were encountered: