Skip to main content

Routing

Each app uses the Next.js App Router (apps/<app>/src/app/). Because the production build is a static export, routing is file-based and fully client-rendered after the initial static HTML — there is no server routing layer.

Per-app entry points

PathFilePurpose
/src/app/page.tsxLogin gate
feature routessrc/app/<feature>/page.tsxApp-specific screens

The tracking app additionally ships a styleguide route that renders the design system as a live reference.

TODO: enumerate each app's concrete feature routes here once they stabilise — derive them from apps/*/src/app/**/page.tsx rather than guessing.

Auth gating

@enode/core's auth-guard.tsx (AuthGuard, mounted in each app's layout.tsx) gates access on the stored bearer token. Login happens at /, and the prefetch loaders re-run after login.

Constraints

  • No request-time routing. No Route Handlers that read the request, no Server Actions, no request-dependent middleware — the static export forbids them.
  • trailingSlash: true in prod so exported paths resolve as directories.