From eb118455023c9ce92ce37413c39d61fb88c7566f Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Tue, 20 Jun 2017 16:19:16 +0200 Subject: [PATCH] Simplify example in `readme.md` --- readme.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/readme.md b/readme.md index 54ca082..4562e88 100644 --- a/readme.md +++ b/readme.md @@ -25,14 +25,14 @@ Say we have the following file, `fragment.html`: And our script, `example.js`, looks as follows: ```javascript -var vfile = require('to-vfile'); +var fs = require('fs'); var rehype = require('rehype'); var slug = require('rehype-slug'); rehype() .data('settings', {fragment: true}) .use(slug) - .process(vfile.readSync('fragment.html'), function (err, file) { + .process(fs.readFileSync('fragment.html'), function (err, file) { if (err) throw err; console.log(String(file)); });