Files
agentic-dev/apps/web-next/src/app/page.tsx
Danijel Martinek 2df137c70c chore(plan-9): final verification + changelog summary
Straggler fixes: web-next and web-tanstack app callers did not pass {}
to queryOptions()/caller calls after Plan 9 added .input(z.object({}).strict())
to siteSettings and header procedures. All 360 tests pass, full typecheck
green across 14 packages. Refactor log §7 updated with verification summary.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-06 16:07:36 +02:00

50 lines
1.3 KiB
TypeScript

import Link from "next/link";
import { appRouter } from "@repo/core-api";
import { bindAllProduction } from "../server/bind-production";
export default async function Home() {
await bindAllProduction();
const caller = appRouter.createCaller({});
const [siteSettings, header, articles] = await Promise.all([
caller.marketingPages.siteSettings({}),
caller.navigation.header({}),
caller.blog.listArticles({ status: "published", limit: 20 }),
]);
return (
<main>
<header>
<h1>{siteSettings.siteName}</h1>
{siteSettings.siteDescription ? (
<p>{siteSettings.siteDescription}</p>
) : null}
<nav>
<ul>
{header.items.map((item) => (
<li key={item.href}>
<Link href={item.href}>{item.label}</Link>
</li>
))}
</ul>
</nav>
</header>
<section>
<h2>Latest articles</h2>
{articles.length === 0 ? (
<p>No published articles yet.</p>
) : (
<ul>
{articles.map((a) => (
<li key={a.id}>
<Link href={`/blog/${a.slug}`}>{a.title}</Link>
</li>
))}
</ul>
)}
</section>
</main>
);
}