Skip to content

Commit 93feb3d

Browse files
snapsynapseclaude
andcommitted
Fix canonical, description, and sitemap defects found in search audit
A search indexing audit of knowledge-as-code.com found five source-level defects in the generated demo site. Four are fixed here. The demo home page emitted no rel=canonical. renderPageShell guarded the tag on a truthy canonicalPath, but the home page passes an empty string, which is a valid route rather than a missing one. The adjacent og:url guard already used `!== undefined` correctly, so the two disagreed. The home page is the demo tree's only entry point from the landing site, so it was the worst page to lose a canonical on. Three bridge callers (authority, compare, applies-to) passed no description, producing five pages with an empty meta description tag. Each now derives one from its own entity data, with singular and plural forms agreeing with the counts they interpolate. Six list pages fell through to config.description and shared one identical string. Each now describes its own contents. The root sitemap listed /demo/ with a lastmod that disagreed with the same URL's entry in demo/sitemap.xml. Removing the duplicate leaves demo/sitemap.xml as the single source of truth for the demo tree, which is already advertised in robots.txt and linked from the landing page. MANIFEST.yaml records the new build.js hash via validate-hashes.sh --update. Verified: hashes, validate, eval, verify, and check-links all pass. All 22 sitemap pages now carry a self-referential canonical and a unique, non-empty description; demo/404.html remains noindex and out of the sitemap. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
1 parent cea8a93 commit 93feb3d

15 files changed

Lines changed: 36 additions & 40 deletions

File tree

‎MANIFEST.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ files:
8282

8383
- path: scripts/build.js
8484
role: tooling
85-
hash: sha256:da80cae7d6e661072543189f5ed841b9ea73f3f283508b4b992aaa0118bb18a2
85+
hash: sha256:41fbc565692823f1cb5fbd2002b61c616d06835851cda1d4b01be88c41f35eb3
8686
note: Static site generator
8787

8888
- path: scripts/assets/favicon.svg

‎demo/about.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
:root { --accent: #4fc3f7; }
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
33-
<meta name="description" content="A structured reference tracking example entities across categories.">
33+
<meta name="description" content="How Example Knowledge Base is sourced, verified, and maintained: 2 frameworks, 3 requirements, and 4 provisions from 2 organizations.">
3434
<meta property="og:title" content="About">
35-
<meta property="og:description" content="A structured reference tracking example entities across categories.">
35+
<meta property="og:description" content="How Example Knowledge Base is sourced, verified, and maintained: 2 frameworks, 3 requirements, and 4 provisions from 2 organizations.">
3636
<meta property="og:type" content="website">
3737

3838
<meta property="og:url" content="https://knowledge-as-code.com/demo/about.html">

‎demo/applies-to/federal/index.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
3333

34-
<meta name="description" content="">
34+
<meta name="description" content="1 framework that applies to Federal, with status and effective dates.">
3535
<meta property="og:title" content="Federal">
36-
<meta property="og:description" content="">
36+
<meta property="og:description" content="1 framework that applies to Federal, with status and effective dates.">
3737
<meta property="og:type" content="website">
3838

3939
<meta property="og:url" content="https://knowledge-as-code.com/demo/applies-to/federal/">

‎demo/applies-to/international/index.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
3333

34-
<meta name="description" content="">
34+
<meta name="description" content="1 framework that applies to International, with status and effective dates.">
3535
<meta property="og:title" content="International">
36-
<meta property="og:description" content="">
36+
<meta property="og:description" content="1 framework that applies to International, with status and effective dates.">
3737
<meta property="og:type" content="website">
3838

3939
<meta property="og:url" content="https://knowledge-as-code.com/demo/applies-to/international/">

‎demo/authority/iso/index.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
3333

34-
<meta name="description" content="">
34+
<meta name="description" content="International Organization for Standardization — 1 framework published by this organization.">
3535
<meta property="og:title" content="International Organization for Standardization">
36-
<meta property="og:description" content="">
36+
<meta property="og:description" content="International Organization for Standardization — 1 framework published by this organization.">
3737
<meta property="og:type" content="website">
3838

3939
<meta property="og:url" content="https://knowledge-as-code.com/demo/authority/iso/">

‎demo/authority/nist/index.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
3333

34-
<meta name="description" content="">
34+
<meta name="description" content="National Institute of Standards and Technology — 1 framework published by this organization.">
3535
<meta property="og:title" content="National Institute of Standards and Technology">
36-
<meta property="og:description" content="">
36+
<meta property="og:description" content="National Institute of Standards and Technology — 1 framework published by this organization.">
3737
<meta property="og:type" content="website">
3838

3939
<meta property="og:url" content="https://knowledge-as-code.com/demo/authority/nist/">

‎demo/compare.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
:root { --accent: #4fc3f7; }
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
33-
<meta name="description" content="A structured reference tracking example entities across categories.">
33+
<meta name="description" content="Compare any two or three of 2 frameworks side by side to see where their coverage overlaps and diverges.">
3434
<meta property="og:title" content="Compare">
35-
<meta property="og:description" content="A structured reference tracking example entities across categories.">
35+
<meta property="og:description" content="Compare any two or three of 2 frameworks side by side to see where their coverage overlaps and diverges.">
3636
<meta property="og:type" content="website">
3737

3838
<meta property="og:url" content="https://knowledge-as-code.com/demo/compare.html">

‎demo/compare/iso-27001-vs-nist-csf/index.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,9 @@
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
3333

34-
<meta name="description" content="">
34+
<meta name="description" content="ISO/IEC 27001:2022 vs NIST Cybersecurity Framework: 1 shared requirement and where the two diverge.">
3535
<meta property="og:title" content="ISO/IEC 27001:2022 vs NIST Cybersecurity Framework">
36-
<meta property="og:description" content="">
36+
<meta property="og:description" content="ISO/IEC 27001:2022 vs NIST Cybersecurity Framework: 1 shared requirement and where the two diverge.">
3737
<meta property="og:type" content="website">
3838

3939
<meta property="og:url" content="https://knowledge-as-code.com/demo/compare/iso-27001-vs-nist-csf/">

‎demo/containers.html‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
:root { --accent: #4fc3f7; }
3131
:is(html, body).light-mode { --accent: #0055aa; }
3232
</style>
33-
<meta name="description" content="A structured reference tracking example entities across categories.">
33+
<meta name="description" content="All 2 frameworks tracked in Example Knowledge Base, with status, effective date, and provision count.">
3434
<meta property="og:title" content="Frameworks">
35-
<meta property="og:description" content="A structured reference tracking example entities across categories.">
35+
<meta property="og:description" content="All 2 frameworks tracked in Example Knowledge Base, with status, effective date, and provision count.">
3636
<meta property="og:type" content="website">
3737

3838
<meta property="og:url" content="https://knowledge-as-code.com/demo/containers.html">

‎demo/index.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<meta name="viewport" content="width=device-width, initial-scale=1.0">
66
<title>Home - Example Knowledge Base</title>
77
<meta name="theme-color" content="#1a1a2e">
8-
8+
<link rel="canonical" href="https://knowledge-as-code.com/demo/">
99
<link rel="icon" href="assets/favicon.svg" type="image/svg+xml">
1010
<link rel="stylesheet" href="assets/styles.css">
1111
<style>/* Generated from project.yml — do not edit manually */

0 commit comments

Comments
 (0)