Add structured data to head

This commit is contained in:
Sacha Weatherstone 2022-03-17 21:06:28 +11:00
parent 8d9eb4d3ce
commit cf50234458
No known key found for this signature in database
GPG key ID: 7AB2D7E206124B31
3 changed files with 42 additions and 1 deletions

View file

@ -13,6 +13,45 @@ const config = {
favicon: "design/web/favicon.ico",
organizationName: "meshtastic",
projectName: "meshtastic",
ssrTemplate: `<!DOCTYPE html>
<html <%~ it.htmlAttributes %>>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="generator" content="Docusaurus v<%= it.version %>">
<% if (it.noIndex) { %>
<meta name="robots" content="noindex, nofollow" />
<% } %>
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"url": "https://meshtastic.org",
"logo": "https://meshtastic.org/design/logo/logo.svg"
}
</script>
<%~ it.headTags %>
<% it.metaAttributes.forEach((metaAttribute) => { %>
<%~ metaAttribute %>
<% }); %>
<% it.stylesheets.forEach((stylesheet) => { %>
<link rel="stylesheet" href="<%= it.baseUrl %><%= stylesheet %>" />
<% }); %>
<% it.scripts.forEach((script) => { %>
<link rel="preload" href="<%= it.baseUrl %><%= script %>" as="script">
<% }); %>
</head>
<body <%~ it.bodyAttributes %>>
<%~ it.preBodyTags %>
<div id="__docusaurus">
<%~ it.appHtml %>
</div>
<% it.scripts.forEach((script) => { %>
<script src="<%= it.baseUrl %><%= script %>"></script>
<% }); %>
<%~ it.postBodyTags %>
</body>
</html>`,
themeConfig: /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ {
colorMode: {
respectPrefersColorScheme: true,

@ -1 +1 @@
Subproject commit b75f60a91abc22367ec017ab0c9eea828784a6ac
Subproject commit 2c19d98137a5461811bcddc83765a4e3699b9452

2
static/robots.txt Normal file
View file

@ -0,0 +1,2 @@
User-agent: *
Disallow: