aa6ede051e
GEO (AI answer engines) — make the signal feeds and case studies machine-citeable: - Dataset JSON-LD on /trump, /kol, /trades (creator=Endorphin, publisher→#org, isAccessibleForFree, temporalCoverage). These are the "data/history/track record" entities Perplexity/Gemini/ChatGPT cite. - case-studies: ItemList of 5 Article nodes, each with headline/description/ articleBody/about + citation→evidence URL + author=Endorphin. ISO dates derived where parseable, omitted for vague labels. - public/llms-full.txt: single-doc full reference (methodology + glossary + case studies w/ sources inlined) for one-fetch AI ingestion; linked from llms.txt. SEO: - Breadcrumbs component (components/seo/Breadcrumbs.tsx) → BreadcrumbList JSON-LD on the 8 indexable content pages (trump/kol/macro/trades/analytics/ methodology/glossary/case-studies). - /archive split into server page + ArchivePageClient; server page sets robots noindex (legacy/test data — thin-content risk). - openGraph added to /trades and /analytics (previously meta+canonical only). Verified: tsc 0 errors, next build passes, runtime curl confirms all JSON-LD types render and llms-full.txt serves 200. No trading/API/component-logic changes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
35 lines
1.1 KiB
TypeScript
35 lines
1.1 KiB
TypeScript
// Emits a schema.org/BreadcrumbList as JSON-LD. Server-component friendly —
|
|
// renders only a <script> tag, no visible DOM. Helps Google breadcrumb rich
|
|
// results and gives AI answer engines the page's entity hierarchy.
|
|
//
|
|
// Usage (server component):
|
|
// <Breadcrumbs items={[{ name: 'Methodology', path: '/en/methodology' }]} />
|
|
// "Home" is prepended automatically; pass the page itself as the last item.
|
|
|
|
const siteUrl = process.env.NEXT_PUBLIC_SITE_URL || 'https://trumpsignal.com'
|
|
|
|
export interface Crumb {
|
|
name: string
|
|
path: string // e.g. "/en/methodology"
|
|
}
|
|
|
|
export default function Breadcrumbs({ items }: { items: Crumb[] }) {
|
|
const all: Crumb[] = [{ name: 'Trump Alpha', path: '/en' }, ...items]
|
|
const jsonLd = {
|
|
'@context': 'https://schema.org',
|
|
'@type': 'BreadcrumbList',
|
|
itemListElement: all.map((c, i) => ({
|
|
'@type': 'ListItem',
|
|
position: i + 1,
|
|
name: c.name,
|
|
item: `${siteUrl}${c.path}`,
|
|
})),
|
|
}
|
|
return (
|
|
<script
|
|
type="application/ld+json"
|
|
dangerouslySetInnerHTML={{ __html: JSON.stringify(jsonLd) }}
|
|
/>
|
|
)
|
|
}
|