あなたにSEOを加えてください
すべてのページでフロント問題を追加
---
title: "Page Title"
metatitle: "Page Meta Title"
metadescription: "Page Meta Description"
image: Image Address
---
データのURLを追加
site.json
に_data
ファイルを作る{
"url": "https://yoursiteurl.com"
}
プライマリタグ
あなたの
base.njk
またはnjk
を加えたあなたのメイン<head>
にこれらを加えてください<title>{{ title }}</title>
<meta name="title" content="{{ metatitle }}">
<meta name="description" content="{{ metadescription }}">
オープングラフ
<meta property="og:type" content="website">
<meta property="og:url" content="https://example.com{{page.url}}">
<meta property="og:title" content="{{ metatitle }}">
<meta property="og:description" content="{{ metadescription }}">
<meta property="og:image" content="{{ site.url + image }}">
自動的にオープングラフ画像を生成する場合は、このpost を読むことができます.<meta property="twitter:card" content="summary_large_image">
<meta property="twitter:url" content="https://example.com{{page.url}}">
<meta property="twitter:title" content="{{ metatitle }}">
<meta property="twitter:description" content="{{ metadescription }}">
<meta property="twitter:image" content="{{ site.url + image }}">
サイトマップ
あなたのルートディレクトリに
sitemap.njk
を作ってください.自動的にsitemap.xml.
になります---
permalink: /sitemap.xml
eleventyExcludeFromCollections: true
---
<?xml version="1.0" encoding="utf-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
{% for page in collections.all %}
<url>
<loc>{{ site.url }}{{ page.url | url }}</loc>
<lastmod>{{ page.date.toISOString() }}</lastmod>
</url>
{% endfor %}
</urlset>
ロボット
を作成する
Sitemap: https://www.yoursitename.com/sitemap.xml
User-agent: *
Disallow:
Reference
この問題について(あなたにSEOを加えてください), 我々は、より多くの情報をここで見つけました https://dev.to/mihir27/add-seo-to-you-11ty-website-43m7テキストは自由に共有またはコピーできます。ただし、このドキュメントのURLは参考URLとして残しておいてください。
Collection and Share based on the CC Protocol