html.md

JavaScript library for converting HTML into Markdown

html.md is a JavaScript library that converts HTML into valid Markdown.

Originally based on the Make.text bookmarklet but with cleaner safer code, not to mention a new simple and understandable API.

Standard Usage

Convert an HTML element or string in to Markdown.

md(html[, options])

Configuration

The behaviour of html.md can easily be configured further to suit your needs by passing an object as the second argument to the main call.

options.debug = true

Whether or not debug information is logged in the console.

Miscellaneous

The html.md API exposes some properties and methods which may only be useful to users in special cases.

md.noConflict()

Relinquish html.md's control of the md global variable. If another library uses this variable calling this method will reassign it back to that library.

md.VERSION

The current version of html.md.

Bugs

If you have any problems with this library or would like to see the changes currently in development browse our issues.

Questions?

Take a look at the documentation to get a better understanding of what the code is doing.

If that doesn't help, feel free to follow me on Twitter, @neocotic.