Skip to content

Instantly share code, notes, and snippets.

@dyoder
Last active August 29, 2015 14:09
Show Gist options
  • Save dyoder/764a1c964685121c299f to your computer and use it in GitHub Desktop.
Save dyoder/764a1c964685121c299f to your computer and use it in GitHub Desktop.
{readFileSync, writeFileSync} = require "fs"
marked = require "marked"
try
markdown = (readFileSync "my-blog-post.md").toString()
html = marked markdown
writeFileSync "my-blog-post.html", html
catch error
console.error error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment