• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

ancane/markdown-preview-mode: Minor mode to preview markdown output as you save

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

ancane/markdown-preview-mode

开源软件地址(OpenSource Url):

https://github.com/ancane/markdown-preview-mode

开源编程语言(OpenSource Language):

Emacs Lisp 91.8%

开源软件介绍(OpenSource Introduction):

Markdown preview mode

MELPA Stable MELPA

Markdown preview in emacs features:

  • on save/idle preview update
  • scroll sync
  • custom/extra css and javascript
  • remote preview
  • multiple simultaneous previews

Install

  • package-install markdown-preview-mode
  • el-get-install markdown-preview-mode

Markdown processor

markdown-preview-mode depends on markdown-mode for markdown processor, defined by markdown-command and it is markdown by default. Please, make sure it is in your $PATH.

Run

  • markdown-preview-mode - start mode and open preview window.
  • markdown-preview-open-browser - open preview window for current buffer.
  • markdown-preview-cleanup - cleanup running processes (close websocket and http servers).

Customize

  • customize-option markdown-command - change markdown processor; take a look at multimarkdown
  • customize-option browse-url-browser-function - change the browser.
  • customize-option markdown-preview-host - change http/websocket server address.
  • customize-option markdown-preview-ws-port - change websocket server port.
  • customize-option markdown-preview-http-port - change http server port.
  • customize-option markdown-preview-auto-open - change the way preview window is open.

Remote access

  • Customize markdown-preview-host to 0.0.0.0.
  • Customize markdown-preview-http-host to 0.0.0.0.
  • Set markdown-preview-auto-open to nil to disable window opening at remote emacs server.
  • Start markdown-preview-mode. Http link for preview will be printed to *Messages* buffer. If not - run markdown-preview-open-browser to get the link printed.
  • Setup 2 tunnels for 0.0.0.0:7379 and 0.0.0.0:9000 and then open preview link in local browser. Adjust tunnels according to your custom ws-port and http-port settings.

Extra css

Add extra css to default solarized dark theme

(add-to-list 'markdown-preview-stylesheets "https://raw.githubusercontent.com/richleland/pygments-css/master/emacs.css")

Override theme completely

(setq markdown-preview-stylesheets (list "http://thomasf.github.io/solarized-css/solarized-light.min.css"))

Extra javascript

Add MathJax

(add-to-list 'markdown-preview-javascript "http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_CHTML")

async

(add-to-list 'markdown-preview-javascript '("http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_CHTML" . async))

Dependencies




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap