今天在重新安装sublime text 3的相关插件。
当安装OmniMarkupPreviewer插件时,遇到如下问题:
每当我希望在网页上实时预览md文件时,页面会报错误
"Error: 404 Not Found
Sorry, the requested URL 'http://127.0.0.1:51004/view/29' caused an error:
'buffer_id(44) is not valid (closed or unsupported file format)'
NOTE: If you run multiple instances of Sublime Text, you may want to adjust
the server_port option in order to get this plugin work again."
单纯的修改server_host
和server_port
并不能生效
解决方案为在Preferences-Package settings-OmniMarkupPreviewer-Settings User
文件内添加设置
{
"renderer_options-MarkdownRenderer": {
"extensions": ["tables", "fenced_code", "codehilite"]
}
}
保存重启即可。
MAC用户修改方法
想要查看更多关于该问题的讨论可以点击链接:
https://github.com/timonwong/OmniMarkupPreviewer/issues/85
更多有关OmniMarkupPreviewer的安装配置详细博客推荐:
http://blog.leanote.com/post/54bfa17b8404f03097000000#fn:attrlist