Skip to content

Commit 84f44a6

Browse files
committed
Fix example
1 parent 50f38b0 commit 84f44a6

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

readme.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -34,22 +34,22 @@ Say we have the following `example.html`:
3434
…and next to it, `example.js`:
3535

3636
```js
37-
var unified = require('unified')
38-
var parse = require('rehype-parse')
39-
var stringify = require('remark-stringify')
40-
var vfile = require('to-vfile')
41-
var toMdast = require('hast-util-to-mdast')
37+
import unified from 'unified'
38+
import remarkParse from 'rehype-parse'
39+
import remarkStringify from 'remark-stringify'
40+
import vfile from 'to-vfile'
41+
import {toMdast} from 'hast-util-to-mdast'
4242

4343
var file = vfile.readSync('example.html')
4444

4545
var hast = unified()
46-
.use(parse)
46+
.use(remarkParse)
4747
.parse(file)
4848

4949
var mdast = toMdast(hast)
5050

5151
var doc = unified()
52-
.use(stringify)
52+
.use(remarkStringify)
5353
.stringify(mdast)
5454

5555
console.log(doc)

0 commit comments

Comments
 (0)