我正在使用 Rmarkdown 并编写 PDF。我想在(a) 不创建列表的情况下开始一个段落。添加\(a)有效,但它突出显示了我的 Rmd 文件文本的其余部分,使其难以阅读。有没有其他方法表明我不想在 Rmarkdown 中创建列表?
---
title: "Untitled"
output:
pdf_document: default
html_document: default
---
This is the first paragraph.
```{r, include=FALSE}
1+1 # nice highlighting before problem
```
(a) This should be the second paragraph. (b) But it is interpreted as a list.
\(a) This slash works to keep the text as a paragraph, but it highlights all remaining text in my Rmd file, which makes it hard to read. (b) Is there another method to use (a) without creating a list?
Here is a good list, but still wrong color in Rmd:
(a) One
(b) Two
```{r, include=FALSE}
1+1 # bad highlighting after problem
```
Run Code Online (Sandbox Code Playgroud)
尝试将 (a) 放入<span>类似
<span> (a) </span> This should be the second paragraph.
Run Code Online (Sandbox Code Playgroud)
这有点 hacky,但它适用于 html 和 pdf,并且修复了突出显示问题。
| 归档时间: |
|
| 查看次数: |
337 次 |
| 最近记录: |