Add the NestJS backend with PostgreSQL and Redis, local setup, and independent frontend and fullstack source archives. Enforce permissions across redirects, let users dismiss the 403 page, and restore missing translation warnings in development.
3.8 KiB
Routing, menus, and permissions
Use this topic to add pages or menus, debug direct navigation and reloads, or change dynamic route sources and configuration. Read the relevant sections of the routing integration and configuration contract first.
| Question | Read first | Follow through |
|---|---|---|
| Static page registration and menu order | Initial route JSON, route module assembly | Views, menu store, shared route expansion |
| Dynamic JSON fields, validation errors, and allowed views | Shared schema, JSON Schema export, application view-ID registry | Application binding, management page, reader guide |
| Static, local, and remote sources and fallback | Source loading and saving | Router initialization, registered routes |
| Menu visibility, direct access, and post-login landing | Navigation guards, route and allowlist configuration | Menu visibility, session store, shared navigation traversal |
The application schema is a re-export. The shared package owns generic validation; the application supplies view loaders, roles, and login state. Keep route names unique. For cached views, check that component names match route names. Frontend menus and guards do not replace server-side authorization.
Targeted verification: pnpm harness verify routing. Start with dynamic configuration and permission regressions. For behavior changes, also check menu entry, direct access, reload, and source switching. Consult layout and state when caching or settings are involved.