Privacy-friendly analytics only with consent. No ads, no cross-site tracking. Read the privacy policy · Manage preferences.
@slipstream-ui/core ships pure-function SEO helpers in utils/seo plus the JsonLd component. No router is a hard dependency — you map the outputs onto your framework's head API.
buildSeoMetadata returns title, description, canonical, robots, Open Graph and Twitter card fields. Feed it to whichever head API your router uses.
import type { Metadata } from 'next';import { buildSeoMetadata } from '@slipstream-ui/core';const site = { name: 'Acme Docs', url: 'https://docs.acme.dev' };export const metadata: Metadata = buildSeoMetadata({site,title: 'Pricing',description: 'Simple, transparent pricing.',path: '/pricing',image: { url: '/og/pricing.png', width: 1200, height: 630 },});
Next accepts openGraph, twitter, alternates.canonical and robots directly — map canonical to alternates.canonical if you prefer explicit keys.
import { Head } from '@inertiajs/react';import { buildSeoMetadata } from '@slipstream-ui/core';const site = { name: 'Acme Docs', url: 'https://docs.acme.dev' };export default function Pricing() {const meta = buildSeoMetadata({site,title: 'Pricing',description: 'Simple, transparent pricing.',path: '/pricing',});return (<><Head><title>{meta.title}</title><meta name="description" content={meta.description} />{meta.canonical && <link rel="canonical" href={meta.canonical} />}<meta property="og:title" content={meta.openGraph.title} /><meta property="og:description" content={meta.openGraph.description} /><meta property="og:url" content={meta.openGraph.url} /><meta property="og:site_name" content={meta.openGraph.siteName} /><meta name="twitter:card" content={meta.twitter.card} /></Head>{/* page content */}</>);}
import { buildSeoMetadata } from '@slipstream-ui/core';const site = { name: 'Acme Docs', url: 'https://docs.acme.dev' };export async function clientLoader() {// meta() runs per-route; build inside the route module.}export function meta({ location }: { location: Location }) {const seo = buildSeoMetadata({site,title: 'Pricing',description: 'Simple, transparent pricing.',path: location.pathname,});return [{ title: seo.title },{ name: 'description', content: seo.description },{ tagName: 'link', rel: 'canonical', href: seo.canonical },{ property: 'og:title', content: seo.openGraph.title },{ property: 'og:description', content: seo.openGraph.description },{ name: 'twitter:card', content: seo.twitter.card },];}
Six builders cover the common entities. Each returns a plain schema.org object — render it with JsonLd in React, or serializeJsonLd in non-React SSR.
| Builder | Emits |
|---|---|
organizationJsonLd(site) | Organization with logo, sameAs, contact point |
webSiteJsonLd(site, description?) | WebSite with publisher and language |
softwareApplicationJsonLd(input) | SoftwareApplication + Offer, version, repository |
articleJsonLd(input) | Article with dates, author, publisher |
faqJsonLd({ site, items }) | FAQPage from visible Q&A pairs |
breadcrumbJsonLd({ site, items }) | BreadcrumbList with numbered items |
import {JsonLd,articleJsonLd,breadcrumbJsonLd,faqJsonLd,organizationJsonLd,webSiteJsonLd,} from '@slipstream-ui/core';const site = { name: 'Acme Docs', url: 'https://docs.acme.dev' };export default function ArticlePage({ post }) {return (<article><JsonLd data={articleJsonLd({site,headline: post.title,description: post.excerpt,url: '/blog/' + post.slug,datePublished: post.publishedAt,dateModified: post.updatedAt,})} /><JsonLd data={breadcrumbJsonLd({site,items: [{ name: 'Home', url: '/' },{ name: 'Blog', url: '/blog' },{ name: post.title, url: '/blog/' + post.slug },],})} />{/* visible article content — schema must match what's on the page */}</article>);}
Structured data must describe content visible on the page — FAQ markup for hidden Q&A or Article markup for unrelated posts can earn a manual action.
sitemapXml and robotsTxt serialize the two crawler files every site needs. Serve them from a route handler or static file.
import { robotsTxt, sitemapXml } from '@slipstream-ui/core';const site = { name: 'Acme Docs', url: 'https://docs.acme.dev' };// app/sitemap.ts (Next.js) or a build-time scriptexport function sitemap() {return sitemapXml(site, [{ url: '/', changefreq: 'weekly', priority: 1 },{ url: '/docs', lastmod: '2026-01-15' },{ url: '/blog/hello-world', lastmod: '2026-01-10', changefreq: 'monthly' },]);}// app/robots.tsexport function robots() {return robotsTxt({site,disallow: ['/admin', '/api'],});}