wooorm/remark plugin for kmuto/review
npm i remark-cli remark-review
See here for more details.
remark --use remark-review document.md --output
If you configure via rc
file, you should type below.
remark document.md
Inspired by pandoc-crossref.
![Caption](file.ext){#fig:label}
$$
x^2 + y^2 = r^2
$$
: Equation of a circle {#eq:label}
| a | b | c |
| :-: | :-: | :-: |
| 1 | 2 | 3 |
: Caption {#tbl:label}
# Section {#sec:section}
```js
console.log('Hello World!');
```
: Caption {#lst:label}
[@fig:label1] or [@fig:label1;@fig:label2;...]
[@jones99] or [@jones99;@smith06;...]
<!-- RAW: //indepimage[unixhistory2] -->
<!--
RAW:
//graph[sin_x][gnuplot][Gnuplotの使用]{
plot sin(x)
//}
-->
Field | Description |
---|---|
baseTemplate | The document template |
documentInfo | The data passed to the base template |
imageConfigs | \includegraphics configs |
templatesDir | Template folder for AST (See templates ) |
You can use ejs template.
remark-review read baseTemplate
and bind documentInfo
to output.
#@# ReVIEW Template written by ejs format.
#@# Render results will be exported as `body`.
<%= body %>
You can configure via rc
file (e.g. remarkrc.json
, remarkrc.yml
).
See also here.
# Required
output: true
plugins:
- remark-review
# Optional
# NOTE: You should put remark-review configs under `review`.
settings:
review:
baseTemplate: review/template.re
imageConfigs:
scale: 0.85
You can configure each files via YAML Frontmatter. See also here
---
baseTemplate: ./review/template.re
---
# Hello World
Lorem ipsum dolor sit amet...
PRs accepted.