next-zonesv0.1.0

Root URLs: aliases

A zone's routes live under its mount, but sometimes a URL must sit at the root: a short share link, a public profile, a legacy address.

export default zoneConfig({
  mount: "/blog",
  aliases: [{ source: "/post/:id", destination: "/blog/:id" }],
});

What the user sees#

Rules#

An alias is refused if:

When a zone image without the alias is installed, the alias stops resolving.

Running a zone alone (next build, next start, next dev): zoneConfig adds the aliases to the zone's own rewrites, so the zone answers them alone too. A build for Zones (next-zones build) leaves them out: Zones serves them.

Edit this page on GitHub · Markdown