Guidance on getting 'Run examples' link to work on generated documentation page
echelleburns opened this issue · 5 comments
When you create an example in the documentation for a function in a new package, the "Run examples" link becomes available on the generated help page. Simply clicking the "Run examples" link returns a page that says "/Example/[function name] not found". How do we create a working link that shows a page with the results of the function's example?
I'm fairly sure this is an RStudio IDE and base R issue. I think it's best to start a conversation around this on Posit Community:
I also see this issue: rstudio/rstudio#12170
It's not in scope for the book.
@echelleburns Have you found a solution for this? I have the same problem and can't seem to find any relevant answers. (Sorry to hijack the book's issues section, @jennybc )
@mariadelmarq - It seems like the issue resolves itself when loading the completed package into your environment using the library()
function, after downloading the complete package via github.
What @echelleburns says ☝️ has the ring of truth for me. It would make sense that this does not work if you're only looking at "dev docs". There are other known limitations, for example, crosslinks do not work. To fully experience the docs in all of their glory, yeah, you need to properly install the package.
Thanks heaps, both!