Skip to content

Latest commit

 

History

History
62 lines (45 loc) · 2.41 KB

README.md

File metadata and controls

62 lines (45 loc) · 2.41 KB

Sublime Text 2 MarkDown preview

A simple ST2 plugin to help you preview your markdown files quickly in you web browser.

Markdown can be converted to Html sing different parsers:

If you have the ST2 LiveReload plugin, your browser will autorefresh the display when you save your file :)

NOTE: If you choose the GitHub API for conversion (set parser: github in your settings), your code will be sent through https to github for live conversion. You'll have Github flavored markdown, syntax highlighting and EMOJI support for free ❤️ :octocat: 🎁

Installation :

  • you should use sublime package manager
  • use cmd+shift+P then Package Control: Install Package
  • look for Markdown Preview and install it.
  • If you are going to use Pandoc to process markdown, install it before. pandoc executable should be on your PATH.

Usage :

  • use cmd+shift+P then Markdown Preview to launch a preview

  • or bind some key in your user key binding, using a line like this one: { "keys": ["alt+m"], "command": "markdown_preview", "args": {"target": "browser"} },

  • once converted a first time, the output HTML will be updated on each file save (with LiveReload plugin)

  • to use Github API for conversion, set plugin settings.

    {
    	"parser": "github",
    }
    
  • to use pandoc for conversion, set plugin settings. args are Pandoc-specific parameters. To change default html template, which is used for conversion, refer to templates/pandoc.html5 file.

    {
    	"parser": "pandoc",
    	"pandoc": {
    		"args": ["-t", "html5", "-s", "--highlight-style", "pygments", "--mathml"]
    	}
    }
    

Uses :

Licence :

The code is available at github https://github.com/revolunet/sublimetext-markdown-preview under MIT licence : http://revolunet.mit-license.org