YAML options in rmarkdowns

Hi everyone,

I'd like to have my contact info (e.g. mail) appear on the markdown title just like the author and date so what's the YAML option that enables me to do so?

Thanks :slightly_smiling_face:

Just put email: "you@address.xxx" in the YAML header

JW

1 Like

It worked thanks for your help Jan. The key was to make the email as a subcategory of the author.

Any idea how I could change the color of mail as the blue won't appear properly due to the background?

Thanks

Unfortunately I never looked into that, so I cannot offer further help here.

1 Like

Ok I understand, Thanks Jan

I see that the email clause generates the following html (note the class):

<a href="mailto:dummy@gmail.com" class="email">dummy@gmail.com</a>

Therefore you can change the color for (all parts of the document with) this class with (note the style section):

---
title: "my title"
author:
  - name : "Mohamed_Fergany" 
    email: dummy@gmail.com
date: "28 Feb 2022"
output: html_document
---

```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
```
<style>
    .email {
        color: red;
    }
</style>

start of the actual document
3 Likes

dummy@gmail :grin: :grin:
but yeah it worked thanks for your help :+1: :+1:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.