Comments (4)
I believe this is not an issue with jss_article()
- this is broader and will happen with any vignettes built with rmarkdown engine with format not embeding the image (as html_vignette()
or other format is doing.
This is directly related to rstudio/rmarkdown#2024 where fig.path
will be set to absolute path when outpur_dir
is used. and IMO is an hidden issue with vignette since knitr 1.27 as the vignette engine is using output.dir
yihui/knitr@b80ece1
Definitely something we should fix somehow.
As a workaround for you need, you can customize the fig path in a setup chunk
```{r include = FALSE}
knitr::opts_chunk$set(
fig.path = "figures/"
)
```
This will correctly use relative paths, and should not be a problem. Though you need to pay attention to chunk name for figures if you have several Rmds and one global folder, or use something like fig.path = "figures/foo-"
I'll add more insight in rstudio/rmarkdown#2024 based on this report as I see vignettes issue more clearly now.
Thanks for the report. i'll close as we need to handle this in rmarkdown
BTW about vignette building
See this discussion r-lib/devtools#2488 where devtools::build_vignettes()
is no more recommended.
The recommended workflow is now the following: https://r-pkgs.org/vignettes.html#sec-vignettes-workflow-writing
This doesn't solve the issue but could be helpful with resources handling.
from rticles.
Thank you! The workaround works like a charm!
from rticles.
Great. You just need to make sure that resources in vignettes/
are correctly included for your R CMD CHECK to pass.
Useful R-HUB blog post
HTML vignettes does not have such issue because images are embeded inside the HTML and not are external resources
from rticles.
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.
from rticles.
Related Issues (20)
- Cannot render a document with the arxiv template (pdfTeX error (font expansion): auto expansion is only possible with scalable fonts) HOT 1
- \textit does not work in a caption in bioinfo.cls HOT 1
- Fix CI issues HOT 1
- Use new addition in pre_knit for metadata processing
- Biobliography not formatted correctly in rticles::elsevier_article HOT 17
- Feature request: Support journals from the American Psychological Association (APA)
- sim_article update HOT 14
- Pandoc 3.1.7 new citeproc for LaTeX breaks some formats
- Add a template for Journal of Experimental Biology HOT 2
- Cross-referencing figures in Copernicus template does not work HOT 4
- Release rticles 0.26 HOT 1
- Taylor & Francis Reference Style needs updating HOT 5
- Unexpected behaviours when making tables for copernicus articles HOT 3
- request for a template for a project MUSE journal HOT 1
- PNAS template not knitting :(
- Error in OUP skeleton.Rmd HOT 2
- JOSS template error with bookdown HOT 1
- Copernicus Publications Correspondence Line Bugfix
- Release rticles 0.27
- I found there has similar error and try to modify the tex file but the outcome doesn't appear the latin greek letters. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rticles.