简体   繁体   中英

How to preview Github flavored markdown offline in Sublime Text 3

I am using sublime text 3 to edit Github flavored markdown file and install sublimetext-markdown-preview . Its document said

Markdown Preview can actually handle them in a couple of ways: online and offline.

However, I didn't find out how to switch it from online to offline after I went through the documents.

I guess sublimetext-markdown-preview don't support offline Github flavored markdown native, and require to install an external markdown parsers locally which supports Github flavored markdown.

Does any body have some hints to me?

And which offline markdown parser can handle Github flavored markdown without accessing to network to Github APIs? I searched on google but don't find that kind of parser.

The repository tagged here has actually been archived. The new Sublime Markdown Preview repository can be accessed here .

And according to the documentation, the GitHub flavored markdown using the GitHub Markdown API is only available online.

I use the MarkdownPreview plugin for previewing GitHub flavored markdown offline (without an internet connection).

Here's the setup:

  • Using Package Control install MarkdownPreview

  • The default key binding to open the markdown file in the default browser is alt+m

You can explicitly add a custom key binding, browser, parser, etc. by going to "Sublime Text" > "Preferences" > "Key Bindings".

I have the following in the user settings (right side):

[
    {
        "keys": ["ctrl+shift+v"],
        "command": "markdown_preview",
        "args": {
            "target": "browser",
            "parser": "github"
        },
        "image_path_conversion": "absolute",
        "file_path_conversions": "absolute",
    }
]

More information available here

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM