Skip to main content

ARC 2.0.0-beta.25

Routes and locales reference

Map declared pages and content to route families, then add locale variants without duplicating a site tree.

This table is the current route-family reference. It describes a route shape, not permission to claim every future slug is collision-free.

DeclarationRoute family
pages/index/Home page /
pages/about/Named page /about/
content/articles/first-post/Collection and detail family such as articles/first-post/
Tagged content collectionarticles/tags/<tag>/ and pagination form
Archive-enabled collectionYear/month archive family

search is a built-in path. Within a collection, tags, page, and feed.xml have dedicated meanings. Archive, pagination, tag, and feed rules can therefore shadow names that would otherwise look like ordinary slugs. Pick collection type names and common slugs before a large content migration, then build and inspect the relevant route family.

Locale variants

Declare the default and supported locale set in .web/site.yaml:

yaml
locale: en
locales:
  - en
  - zh

Then use sibling locale variants only where content changes:

DefaultLocale variant
content.mdcontent.zh.md
layout.auplayout.zh.aup
seo/titleseo/title.zh
seo/descriptionseo/description.zh

The runtime can derive a compatibility locale set from .aup/locales/*.json when locales is absent. A new site should declare the actual supported set in site.yaml; it gives authors, build, and review one explicit contract. Do not add en/ and zh/ directories under every page/object to create translations of the same thing.

Navigation is not routing. A menu link does not create a page, and a page directory does not decide which menu should expose it. Resolve the route first, then make a separate information-architecture choice for navigation.

For a walkthrough, read Routes, navigation, and locales.