vscode中设置markdown的snippet

Posted by liumh on December 4, 2019     view:

vscode中设置markdown的snippet


问题: 在vscode的markdown.json中添加以下snippet后,在markdown文件中输入eq无法调出以下代码。

"equation": {
    "prefix": "eq",
    "body": [
        "$$",
        "\\begin{equation}",
        "$1",
        "\\end{equation}",
        "$$",
        "$0"
    ],
    "description": "latex equation"
},

解决方案: 在vscode的配置文件setting.json中添加以下设置:

"[markdown]": {
    "editor.quickSuggestions": {
        "other": true,
        "comments": true,
        "strings": true
    },
}

参考文章:

  1. Vscode Markdown Snippet 配置