打开VS Code找到设置-用户代码片段-html然后在json文件里添加如下代码:
{
"HTML Snippets": {
"prefix": "!doc",
"body": [
"<!DOCTYPE html>",
"<html>",
"\t<head>",
"\t\t<meta charset=\"UTF-8\" />",
"\t\t<meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0, user-scalable=false\" />",
"\t\t<title>$1</title>",
"\t</head>",
"\t<body>",
"\t\t$0",
"\t</body>",
"</html>"
],
"description": "HTML Template"
}
}