Skip to content
Find file
Fetching contributors…
Cannot retrieve contributors at this time
33 lines (23 sloc) 698 Bytes


Express middleware for rendering markdown files

It looks for URLs ending in ".md" or ".markdown", example:


npm install express-markdown


// !!!IMPORTANT: place this before static or similar middleware

  // directory where markdown files are stored
  // required
  directory: __dirname + '/public', 

  // view to use for rendering markdown file
  // optional
  // default is undefined, no view
  view: 'foo',

  // name of markdown variable passed in the context when rendering
  // optional
  // default 'markdown'
  variable: 'bar'

Jump to Line
Something went wrong with that request. Please try again.