-
Notifications
You must be signed in to change notification settings - Fork 1
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
HTML page formatting to match Github Page #14
Comments
The CSS controls appearance. To match your website you need to apply the same CSS. You can go into the assets folder and download the CSS into the folder with your RMD file. Then there is a CSS option for YAML where you can specify a CSS file. The file you reference will override the default RMD style options. |
You can add style events to an RMD document by placing the CSS arguments between <style></style> tags in your document. |
@lecy thanks so much! |
You can also add header and footer sections to your RMD, but you need static HTML pages. The current versions of header.html and footer.html in the _includes folder of your website include Jekyll liquid tags. RMD will not know what to do with these, so you would probably need to create static versions. If you have static header and footer sections you would add them as follows:
Lots more options here: https://bookdown.org/yihui/rmarkdown/html-document.html#advanced-customization |
I just wanted to follow up and say that I figured it out using the R HTML format in RStudio and I was able to create the following page: https://castower.github.io/wordcloud2/ |
This is great! Did you update the YAML header settings in the RMD file, or copy the HTML code into a GitHub page? |
@lecy I used the R HTML template in RStudio to export the file to an html that I uploaded to the repository. I then changed the file extension to .md and added the YAML header under GitHub pages. I also added a few extra HTML and CSS codes for the photos and table of contents. |
Hello all,
While working on the github page website, I've figured out how to make the
.md
files match the theme by adding a YAML header, but I'm not sure how to do this for.html
files. Has anyone discovered if it is possible to create a.html
file on RStudio and make it match the overall website theme? Specifically, I'd like to be able to create a.html
file that can display R Code Output, but also have the same style and include the header of my site so that I can click through all the pages instead of having to hit the back button/lose the header options.Thanks!
Courtney
The text was updated successfully, but these errors were encountered: