Closed flipacholas closed 2 years ago
Yes, it should include epub2
. Would you like to send a pull request? Thanks!
Done!
This old thread has been automatically locked. If you think you have found something related to this, please open a new issue by following the issue guide (https://yihui.org/issue/), and link to this old issue if necessary.
By filing an issue to this repo, I promise that
xfun::session_info('knitr')
. I have upgraded all my packages to their latest versions (e.g., R, RStudio, and R packages), and also tried the development version:remotes::install_github('yihui/knitr')
.I understand that my issue may be closed if I don't fulfill my promises.
My session:
I think there is (undesirable?) behaviour present when rendering epubs using the
epub_version
attribute set toepub2
. Basically, after embedding images on a document with caption (usingfig.caption
), if the document is rendered using bookdown andepub_version
is set toepub3
orepub
, knitr will render<p class="caption">
block with the caption (as expected). On the other hand, if it's set toepub2
, the caption block is not rendered.At first, I thought this was an issue of bookdown, but I found this line that may be the culprit:
https://github.com/yihui/knitr/blob/17ef462e3b5e8fa344556e05c9a9833225ccca4c/R/utils.R#L382
(probably should include "epub2" as well?)