A simple html to markdown converter that converts html to markdown, using no dependencies. Perfect for react-native.
My own use case for this is quite simple. If it doesn't quite fit yours, PRs are welcome!
- h1,h2,h3,h4,h5,h6
- p
- ul,ol
- blockquote,
- pre
- bold,strong
- italic,em
- a
- br
var converter = require('html-to-markdown');
var markdown = converter.convert('<h2> Happy Journey </h2>');
var converter = require('html-to-markdown');
converter.use(function (html) {
// making required changes
// and return new html
})
This was forked from https://github.com/thetutlage/html-to-markdown, which was a good start but is no longer maintained.