Skip to content

Commit 7eae49f

Browse files
committed
Update readme
1 parent 104ddb0 commit 7eae49f

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -114,36 +114,36 @@ const processor = unified()
114114
.use(docx, { plugins: [shikiPlugin({ theme: "dark-plus" })] });
115115
```
116116

117-
### HTML
117+
### Math
118118

119-
Transform HTML to markdown.
119+
Render LaTeX with [MathJax](https://github.com/mathjax/MathJax).
120120

121121
```javascript
122122
import { unified } from "unified";
123123
import markdown from "remark-parse";
124+
import math from "remark-math";
124125
import docx from "remark-docx";
125-
import { htmlPlugin } from "remark-docx/plugins/html";
126+
import { latexPlugin } from "remark-docx/plugins/latex";
126127

127128
const processor = unified()
128129
.use(markdown)
129-
.use(docx, { plugins: [htmlPlugin()] });
130+
.use(math)
131+
.use(docx, { plugins: [latexPlugin()] });
130132
```
131133

132-
### Math
134+
### HTML
133135

134-
Render LaTeX with [MathJax](https://github.com/mathjax/MathJax).
136+
Transform HTML to markdown.
135137

136138
```javascript
137139
import { unified } from "unified";
138140
import markdown from "remark-parse";
139-
import math from "remark-math";
140141
import docx from "remark-docx";
141-
import { latexPlugin } from "remark-docx/plugins/latex";
142+
import { htmlPlugin } from "remark-docx/plugins/html";
142143

143144
const processor = unified()
144145
.use(markdown)
145-
.use(math)
146-
.use(docx, { plugins: [latexPlugin()] });
146+
.use(docx, { plugins: [htmlPlugin()] });
147147
```
148148

149149
## Documentation

0 commit comments

Comments
 (0)