Add support for images in `/man/figures`
Hi
I tried to create a quarto website of a package (I completely removed the vignettes folder for testing purposes).
I get the following error:
── Update HTML ─────────────────────────────────────────────────────────────────────────────
ERROR: Project _quarto.yml validation failed.
In file D:\D Desktop\Publications\R package squarebrackets\squarebrackets\_quarto\_quarto.yml
(line 6, columns 3--13) property name code-links is invalid
5: title: squarebrackets
6: code-links: true
~~~~~~~~~~~
7: navbar:
i The error happened in location website:code-links.
quarto and altdoc, as well as their dependencies, are up-to-date. And roxygen2, knitr, devtools, pkgdown, are also all up-to-date.
Kind regards,
Tony
Hi, I've never used code-links but from what I can see in the docs they don't accept the value true? Do you have a small example or a link to a repo where this happens?
Hi,
I've not published the repo with altdoc yet, because I wanted to try altdoc on my laptop first.
altdoc creates the _quarto.yml file, I didn't create it, and I didn't touch the values that altdoc specifies.
I see it's specified in altdoc here: https://github.com/etiennebacher/altdoc/blob/b1ff5b4886d370d8465b868049f20c4f8004d4d2/inst/quarto_website/quarto_website.yml#L11
Kind regards,
Tony
I cannot reproduce on one of my packages that doesn't use altdoc. I used the devel version of altdoc and quarto 1.6.40.
Can you report the versions of altdoc and quarto that you use?
altdoc version 0.5.0 quarto version 1.4.4
Can you update quarto and see if that works? I mean the CLI tool, not the R package "quarto"
https://quarto.org/docs/get-started/
Hi,
Yes! that was the issue. The Quarto program was not up-tp-date. The website now works without errors. Thanks for the help!
I did notice a different issue: altdoc is not rendering figures from function help pages.
altdoc points figures to the folder /docs/help/figures/, but that folder is never created by altdoc. The figures in the package are stored in /man/figures/ (as is usally the case for R packages.
Did I forget some kind of configuration?
Kind regards,
Tony
By the way, simply copy-paste-ing the images from _quarto\man\figures to docs\help\figures fixes the issue of missing images.
I could write a simple R script to do it for me everytime I update the website.
But it might be more user-friendly if altdoc does this as part of the render_docs() function.
But it might be more user-friendly if altdoc does this as part of the render_docs() function.
I agree but I can't promise I'll work on this anytime soon. It might be better to use a custom script for this for now.
Just for future me, I think this is the same as https://github.com/etiennebacher/altdoc/issues/7
@tony-aw the automatic copy to docs/help/figures should now be handled by altdoc (dev version). It would be great if you could confirm that with your own package.
I'm using the development version and I still have this error, more specifically
I did notice a different issue: altdoc is not rendering figures from function help pages.
altdoc points figures to the folder /docs/help/figures/, but that folder is never created by altdoc. The figures in the package are stored in /man/figures/ (as is usally the case for R packages.
Did I forget some kind of configuration?
Kind regards,
From the notes it looks like #321 should have addressed but I'm seeing the same issue.
Do you have a repo where you have this issue and that I could use to reproduce the problem?
Do you have a repo where you have this issue and that I could use to reproduce the problem?
https://github.com/usrbinr/contoso
packageVersion("altdoc")
‘0.6.0.9000’
packageVersion("quarto")
‘1.5.1’
quarto -v
1.8.25
```