1 | ;
|
2 |
|
3 | /* Dependencies. */
|
4 | var xtend = require('xtend');
|
5 |
|
6 | var one = require('./one');
|
7 |
|
8 | /* Expose. */
|
9 | module.exports = stringify;
|
10 |
|
11 | /* Stringify the given MDAST node. */
|
12 | function toLaTeX(node, options) {
|
13 | return one(options, node);
|
14 | }
|
15 |
|
16 | /* Compile MDAST tree using toLaTeX */
|
17 | function stringify(config) {
|
18 | var settings = xtend(config, this.data('settings'));
|
19 |
|
20 | this.Compiler = compiler;
|
21 |
|
22 | function compiler(tree) {
|
23 | return toLaTeX(tree, settings);
|
24 | }
|
25 | } |
\ | No newline at end of file |