suan/vim-instant-markdown — pull request #14 by chreekat (2012-11-23 20:48:35+00:00)
Title: A config option and some best practices

Hi there,

Thanks for this plugin. :)

The instantaneous-ness was a bit much for my system, so I've created a configuration option that slows it down some. With `g:instant_markdown_slow = 1`, the display only updates on BufWrite and InsertLeave.

While making this change, however, I noticed that the plugin doesn't conform to vim best practices. I went ahead and implemented some. **This changes the plugin's behavior**, so please note:

1. The plugin is now an 'after/ftplugin', so vim will fire it automatically upon detecting a markdown file.
2. The plugin no longer makes the "is this a markdown" decision itself. That is best done elsewhere.
* If you do want this plugin to provide that functionality, I would suggest creating a file `ftdetect/markdown.vim` that has the setfiletype autocommand. But I think this is clearly a ftplugin and should probably leave that matter separate.