/Knowledge/sources/honojs__hono/llms-full/ssg-helper-middleware-ssgparams--4f682040cf36.md
SSG Helper: Middleware > ssgParams - hono-docs
SSG Helper: Middleware ssgParams Source evidence: /Sources/honojs hono/provenance.md Canonical citation: https://hono.dev/llms full.txt ssgparams Summary You...
SSG Helper: Middleware > ssgParams
Source evidence: /Sources/honojs__hono/provenance.md Canonical citation: https://hono.dev/llms-full.txt#ssgparams
Summary
You can use an API like generateStaticParams of Next.js. Example: ```ts app.get( '/shops/:id', ssgParams(async () => { const shops = await getShops() return shops.map((shop) => ({ id: shop.id })) }), async (c) => { const shop = await g...
Content
You can use an API like generateStaticParams of Next.js.
Example:
app.get(
'/shops/:id',
ssgParams(async () => {
const shops = await getShops()
return shops.map((shop) => ({ id: shop.id }))
}),
async (c) => {
const shop = await getShop(c.req.param('id'))
if (!shop) {
return c.notFound()
}
return c.render(
<div>
<h1>{shop.name}</h1>
</div>
)
}
)
Metadata
{
"chunk_index": 0,
"citation": "https://hono.dev/llms-full.txt#ssgparams",
"coverage_role": "overview",
"qualified_title": "Hono / llms-full / SSG Helper > Middleware > ssgParams",
"retrieved_at": "2026-07-02T05:51:01Z",
"section_index": 751,
"source_id": "/honojs/hono",
"source_type": "llms_full",
"target_label": "llms-full",
"title": "SSG Helper: Middleware > ssgParams",
"upstream_url": "https://hono.dev/llms-full.txt",
"version": "2026"
}