Steps 7a through 10 as one authorised run. Nothing deployed (D11).
7a Lighthouse returns as `lighthouse@13.4.1` + `chrome-launcher`, NOT
`@lhci/cli`. AGENTS.md §7's advisory attribution was wrong: the carriers
were @lhci/cli's own `tmp` and @puppeteer/browsers' `extract-zip`, not
Lighthouse, which audits clean. A deliberate deviation from R11's literal
trigger, recorded with what it costs. Local gate; CI has no Chrome.
7b OG card generator (satori + sharp) discharges R15 — 20 typed cards plus
per-article cards; the portrait stays on / and /about/ by Q40. Insights
plumbing: ArticleCard, Prose, the index, the article route, articleGraph,
and /'s section 7. Card copy is constrained structurally because text in a
JPEG cannot be grepped by check:claims: every headline IS its page's <h1>,
enforced by `npm run og:proof`.
7c Five drafted launch articles, draft: true / reviewedByPouya: false. An
independent compliance audit returned 76 findings and 57 unsourced
assertions; all blocking and should-fix applied.
8 /contact/, the intake form, and backend/intake/ (undeployed). Plain HTML
POST to a same-origin /api/intake with a 303 redirect, so the form works
with zero JavaScript. docs/05 records three deliberate deviations.
9 /fees/ on Q59's ruling — overtime runs from the session cap, and the
reservation point ships adjacent to the rate. One-page PDF bio discharges
R16; /bio/ is its source, so the circulated artefact stays inside the
review apparatus.
10 /legal/privacy/ and /legal/terms/, written to the backend as built. Three
of the policy's statements are derived and cannot drift.
Also: /about/'s inverse credentials band (approved at step 6); Q59 closed;
R15 and R16 discharged; and a fix to shipped copy — /practice/energy/ asserted
the absence of a regulation the source extract says must not be asserted.
Review: adversarial-reviewer, two rounds (D20/D19). Round 1 returned 16
findings including two blocking — an invisible ghost button on /fees/ at
1.00:1 that Lighthouse scored 100, and a privacy policy that named one data
processor when there are two. All 16 acted on.
Lighthouse, 22 pages, mobile: performance 99-100, accessibility 100,
best practices 100, SEO 100 on every indexable page, CLS 0.000.
AGENTS.md entry (ah) has the detail, including four of my own verification
commands that were wrong and what each of them nearly caused.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Md3GndFqWPzK78xAoebsg5
85 lines
4.4 KiB
JavaScript
85 lines
4.4 KiB
JavaScript
import { defineConfig } from 'astro/config';
|
|
import mdx from '@astrojs/mdx';
|
|
import sitemap from '@astrojs/sitemap';
|
|
|
|
// Canonical origin. Drives canonical URLs, OG tags, and the sitemap.
|
|
const SITE = process.env.PUBLIC_SITE_URL ?? 'https://adr.smlcompany.ca';
|
|
|
|
export default defineConfig({
|
|
site: SITE,
|
|
|
|
// Static output is the point of this rebuild — see docs/04-seo-spec.md.
|
|
// Do not switch to a server adapter without an AGENTS.md Change Log entry.
|
|
output: 'static',
|
|
|
|
// Directory-style URLs with a trailing slash, matched by the CloudFront
|
|
// trailing-slash function. See docs/06-deployment.md.
|
|
trailingSlash: 'always',
|
|
build: { format: 'directory', inlineStylesheets: 'auto' },
|
|
|
|
// Astro 7 changed this default from `true` to `'jsx'`. Measured, not assumed
|
|
// (AGENTS.md entry (t)): in an .astro template, an inline pair split across
|
|
// two lines renders as `<em>inline</em><strong>pair</strong>` under 'jsx' and
|
|
// `<em>inline</em> <strong>pair</strong>` under `true`. The space is silently
|
|
// deleted — no error, no warning; you find out by reading the page.
|
|
//
|
|
// MDX prose is NOT affected either way; the hazard is .astro markup only.
|
|
// Held at the HTML-aware behaviour because hand-written templates on a
|
|
// text-heavy site are exactly where a wrapped line meets an inline tag.
|
|
// Revisit only with a measurement, not a preference. See R12.
|
|
compressHTML: true,
|
|
|
|
integrations: [
|
|
mdx(),
|
|
sitemap({
|
|
// NOINDEX PAGES ARE EXCLUDED, and the list is now three shapes rather
|
|
// than one. `/legal/*` is noindex by spec (docs/04). The two added at
|
|
// build step 8 are the intake form's POST-redirect-GET landing pages:
|
|
// both are transactional, neither has standalone value, and a search
|
|
// result reading "your inquiry has been received" for someone who has not
|
|
// sent one is worse than no result at all.
|
|
//
|
|
// ⚠️ `/insights/` IS DELIBERATELY NOT HERE even though it emits
|
|
// `noindex` while no article is published. This filter cannot see
|
|
// collection data — it runs from build config, with no access to
|
|
// `getCollection` — so the exclusion could only be a guess at the
|
|
// collection's state, and it would then be wrong in the direction that
|
|
// matters the moment an article publishes. The page derives its own
|
|
// `noindex` from the collection on every build, so the mismatch is
|
|
// temporary, self-clearing, and reported accurately by Search Console as
|
|
// excluded-by-noindex. Recorded rather than fixed with a frontmatter
|
|
// parser in build config.
|
|
//
|
|
// The `/type-scale/` half of this condition is gone with the page it
|
|
// named: the step-1 proof sheet was deleted at step 2, as its own comment
|
|
// and InfinityMark's both said it would be. Recoverable from git if the
|
|
// specimen is ever wanted again; it is not a route the site ships.
|
|
filter: (page) =>
|
|
!page.includes('/legal/') &&
|
|
!page.includes('/contact/received/') &&
|
|
!page.includes('/contact/could-not-send/') &&
|
|
// `/bio/` is a condensed duplicate of `/about/` and `/fees/`, and it
|
|
// exists to be rendered to a PDF (R16). Two URLs competing on the same
|
|
// content is the thing `docs/04` is most concerned with, so it is
|
|
// `noindex` and out of the sitemap.
|
|
!page.includes('/bio/'),
|
|
changefreq: 'monthly',
|
|
// No `lastmod`. It was `new Date()`, which stamped every URL with the
|
|
// build time — telling crawlers all 17 pages changed whenever one did.
|
|
// Google discounts lastmod it judges unreliable, so that spent the signal
|
|
// docs/04-seo-spec.md wants rather than sending it. Step 7 can reinstate
|
|
// it per-entry from an article's `updatedDate` via `serialize`.
|
|
}),
|
|
],
|
|
|
|
// No `image` block: `astro/assets/services/sharp` is already Astro's default
|
|
// service, so setting it was dead configuration. The conventions it used to
|
|
// sit under — explicit width/height on every image, never base64-inline —
|
|
// live in CLAUDE.md, which is where they are actually enforced (by review).
|
|
|
|
// No `prefetch` block at all — removed 2026-08-26, see AGENTS.md entry (r).
|
|
// Any prefetch setting ships Astro's prefetch script to every page, against
|
|
// CLAUDE.md's "default to zero JS", for a marginal gain on a small static site
|
|
// already served from CloudFront. Revisit only against real Lighthouse numbers.
|
|
});
|