{"id":20520,"date":"2024-11-19T13:44:06","date_gmt":"2024-11-19T05:44:06","guid":{"rendered":"https:\/\/fwq.ai\/blog\/20520\/"},"modified":"2024-11-19T13:44:06","modified_gmt":"2024-11-19T05:44:06","slug":"vscode%e5%88%9b%e5%bb%bahtml%e9%a1%b9%e7%9b%ae%e6%80%8e%e4%b9%88%e8%ae%be%e7%bd%ae%e8%83%8c%e6%99%af%e5%92%8c%e5%ad%97%e4%bd%93","status":"publish","type":"post","link":"https:\/\/fwq.ai\/blog\/20520\/","title":{"rendered":"vscode\u521b\u5efahtml\u9879\u76ee\u600e\u4e48\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53"},"content":{"rendered":"<blockquote><p>\n  \u5982\u4f55\u4f7f\u7528 vscode \u4e3a html \u9879\u76ee\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\u80cc\u666f\u8bbe\u7f6e\uff1a\u65b0\u5efa html \u6587\u4ef6\uff0c\u5728 css \u6837\u5f0f\u8868\u4e2d\u6dfb\u52a0\u80cc\u666f\u8272\u5b9a\u4e49\uff0c\u4f8b\u5982 body {background-color: #f0f0f0;}\u3002\u5b57\u4f53\u8bbe\u7f6e\uff1a\u52a0\u8f7d web \u5b57\u4f53\uff0c\u5c06\u5176\u5bfc\u5165 html \u9875\u9762\uff0c\u5728 css \u6837\u5f0f\u8868\u4e2d\u4f7f\u7528 font-family \u5c5e\u6027\u6307\u5b9a\u5b57\u4f53\uff0c\u4f8b\u5982 body {font-family: &#8216;roboto&#8217;, sans-serif;}\u3002\n<\/p><\/blockquote>\n<p><img decoding=\"async\" src=\"https:\/\/img.php.cn\/upload\/article\/202404\/03\/2024040303362188140.jpg\" class=\"aligncenter\" title=\"vscode\u521b\u5efahtml\u9879\u76ee\u600e\u4e48\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\u63d2\u56fe\" alt=\"vscode\u521b\u5efahtml\u9879\u76ee\u600e\u4e48\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\u63d2\u56fe\" \/><\/p>\n<p><strong>\u5982\u4f55\u4f7f\u7528 VSCode \u4e3a HTML \u9879\u76ee\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53<\/strong><\/p>\n<p><strong>\u80cc\u666f\u8bbe\u7f6e<\/strong><\/p>\n<ol>\n<li> <strong>\u65b0\u5efa HTML \u6587\u4ef6\uff1a<\/strong>\u9996\u5148\u521b\u5efa\u4e00\u4e2a\u65b0\u7684 HTML \u6587\u4ef6\uff0c\u4f8b\u5982 &#8220;index.html&#8221;\u3002<\/li>\n<li> <strong>\u6dfb\u52a0 CSS \u6837\u5f0f\u8868\uff1a<\/strong>\u5728 \u6807\u7b7e\u4e2d\u6dfb\u52a0 \u6807\u7b7e\uff0c\u94fe\u63a5\u5230\u4e00\u4e2a\u5916\u90e8 CSS \u6837\u5f0f\u8868\u3002\u4f8b\u5982\uff1a<\/li>\n<\/ol>\n<pre>&lt;head&gt;\n  &lt;link rel=\"stylesheet\" href=\"style.css\"&gt;\n&lt;\/head&gt;<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<ol>\n<li> <strong>\u5b9a\u4e49 CSS \u6837\u5f0f\uff1a<\/strong>\u5728 &#8220;style.css&#8221; \u6587\u4ef6\u4e2d\uff0c\u6dfb\u52a0\u4ee5\u4e0b CSS \u89c4\u5219\u6765\u8bbe\u7f6e\u80cc\u666f\uff1a<\/li>\n<\/ol>\n<pre>body {\n  background-color: #f0f0f0;\n}<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p><strong>\u5b57\u4f53\u8bbe\u7f6e<\/strong><\/p>\n<ol>\n<li> <strong>\u52a0\u8f7d Web \u5b57\u4f53\uff1a<\/strong>\u9009\u62e9\u5e76\u52a0\u8f7d\u60a8\u60f3\u8981\u7684 Web \u5b57\u4f53\u3002\u60a8\u53ef\u4ee5\u4f7f\u7528 Google Fonts \u6216 Adobe Fonts \u7b49\u670d\u52a1\u3002<\/li>\n<li> <strong>\u5bfc\u5165 Web \u5b57\u4f53\uff1a<\/strong>\u5c06\u52a0\u8f7d\u7684\u5b57\u4f53\u6587\u4ef6\u5bfc\u5165\u60a8\u7684 HTML \u9875\u9762\u3002\u5728 \u6807\u7b7e\u4e2d\u6dfb\u52a0\u4ee5\u4e0b \u6807\u7b7e\uff1a<\/li>\n<\/ol>\n<pre>&lt;head&gt;\n  &lt;link href=\"https:\/\/fonts.googleapis.com\/css2?family=Roboto:wght@400;700&amp;display=swap\" rel=\"stylesheet\"&gt;\n&lt;\/head&gt;<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<ol>\n<li> <strong>\u6307\u5b9a\u5b57\u4f53\u6837\u5f0f\uff1a<\/strong>\u5728 CSS \u6837\u5f0f\u8868\u4e2d\uff0c\u4f7f\u7528 font-family \u5c5e\u6027\u6765\u6307\u5b9a\u60a8\u7684\u5b57\u4f53\u3002\u4f8b\u5982\uff1a<\/li>\n<\/ol>\n<pre>body {\n  font-family: 'Roboto', sans-serif;\n}<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<ol>\n<li> <strong>\u8bbe\u7f6e\u5176\u4ed6\u5b57\u4f53\u5c5e\u6027\uff08\u53ef\u9009\uff09\uff1a<\/strong>\u60a8\u53ef\u4ee5\u4f7f\u7528\u5176\u4ed6 CSS \u5c5e\u6027\u6765\u8fdb\u4e00\u6b65\u81ea\u5b9a\u4e49\u5b57\u4f53\uff0c\u4f8b\u5982 font-size, font-weight \u548c font-style\u3002<\/li>\n<\/ol>\n<p><strong>\u793a\u4f8b HTML \u548c CSS \u4ee3\u7801<\/strong><\/p>\n<p><span>\u7acb\u5373\u5b66\u4e60<\/span>\u201c\u201d\uff1b<\/p>\n<p>\u4ee5\u4e0b\u662f\u4e00\u4e2a\u793a\u4f8b HTML \u548c CSS \u4ee3\u7801\uff0c\u7528\u4e8e\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\uff1a<\/p>\n<pre>\n\n&lt;head&gt;\n  &lt;link rel=\"stylesheet\" href=\"style.css\"&gt;\n&lt;\/head&gt;\n\n  <h1>\u6807\u9898<\/h1>\n  <p>\u6b63\u6587<\/p>\n\n<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<pre>body {\n  background-color: #f0f0f0;\n  font-family: 'Roboto', sans-serif;\n  font-size: 16px;\n  font-weight: 400;\n}\nh1 {\n  font-weight: 700;\n}<\/pre>\n<p> \u767b\u5f55\u540e\u590d\u5236 <\/p>\n<p>\u4ee5\u4e0a\u5c31\u662f\u521b\u5efahtml\u9879\u76ee\u600e\u4e48\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\u7684\u8be6\u7ec6\u5185\u5bb9\uff0c\u66f4\u591a\u8bf7\u5173\u6ce8\u7c73\u4e91\u5176\u5b83\u76f8\u5173\u6587\u7ae0\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5982\u4f55\u4f7f\u7528 vscode \u4e3a html \u9879\u76ee\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53\u80cc\u666f\u8bbe\u7f6e\uff1a\u65b0\u5efa html \u6587\u4ef6\uff0c\u5728 css \u6837\u5f0f\u8868\u4e2d\u6dfb\u52a0\u80cc\u666f\u8272\u5b9a\u4e49\uff0c\u4f8b\u5982 body {background-color: #f0f0f0;}\u3002\u5b57\u4f53\u8bbe\u7f6e\uff1a\u52a0\u8f7d web \u5b57\u4f53\uff0c\u5c06\u5176\u5bfc\u5165 html \u9875\u9762\uff0c\u5728 css \u6837\u5f0f\u8868\u4e2d\u4f7f\u7528 font-family \u5c5e\u6027\u6307\u5b9a\u5b57\u4f53\uff0c\u4f8b\u5982 body {font-family: &#8216;roboto&#8217;, sans-serif;}\u3002 \u5982\u4f55\u4f7f\u7528 VSCode \u4e3a HTML \u9879\u76ee\u8bbe\u7f6e\u80cc\u666f\u548c\u5b57\u4f53 \u80cc\u666f\u8bbe\u7f6e \u65b0\u5efa HTML \u6587\u4ef6\uff1a\u9996\u5148\u521b\u5efa\u4e00\u4e2a\u65b0\u7684 HTML \u6587\u4ef6\uff0c\u4f8b\u5982 &#8220;index.html&#8221;\u3002 \u6dfb\u52a0 CSS \u6837\u5f0f\u8868\uff1a\u5728 \u6807\u7b7e\u4e2d\u6dfb\u52a0 \u6807\u7b7e\uff0c\u94fe\u63a5\u5230\u4e00\u4e2a\u5916\u90e8 CSS \u6837\u5f0f\u8868\u3002\u4f8b\u5982\uff1a &lt;head&gt; &lt;link rel=&#8221;stylesheet&#8221; href=&#8221;style.css&#8221;&gt; &lt;\/head&gt; \u767b\u5f55\u540e\u590d\u5236 \u5b9a\u4e49 CSS \u6837\u5f0f\uff1a\u5728 &#8220;style.css&#8221; \u6587\u4ef6\u4e2d\uff0c\u6dfb\u52a0\u4ee5\u4e0b CSS [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[],"class_list":["post-20520","post","type-post","status-publish","format-standard","hentry","category-16"],"_links":{"self":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/20520","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/comments?post=20520"}],"version-history":[{"count":0,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/posts\/20520\/revisions"}],"wp:attachment":[{"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/media?parent=20520"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/categories?post=20520"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/fwq.ai\/blog\/wp-json\/wp\/v2\/tags?post=20520"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}