// Web app for the {{projectName}} project — SERVER-RENDERED pages. // // Pages here use `renderMode: 'ssr'` (fresh per request) and `'isr'` // (cached + revalidated). Unlike a static site, these need a runtime — // run them with `voltro start` (NOT a bare CDN). The render-mode gate in // `voltro static deploy` will (correctly) refuse to ship them to a pure CDN. // // Self-contained: no `apis` declared, so it boots with zero infra. To pull // fresh data from YOUR reactive backend instead, add an `apis` entry and use // `ctx.query(...)` in the loaders (see src/pages/index.tsx). import { defineEnv, envVar } from '@voltro/env' export const env = defineEnv({ VOLTRO_PUBLIC_APP_NAME: envVar.string({ access: 'public', default: '{{capProjectName}}' }), }) export default { type: 'web' as const, name: '{{capProjectName}}{{capAppName}}', port: {{port}}, theme: 'system' as const, env, // Bilingual by default. The framework auto-wires a cookie-driven // from these codes and loads the matching // `src/locales/.ts` catalog — so `` / `useT()` / // `useLocale()` work app-wide (SSR + ISR too) with no manual setup. The // in the layout writes the `voltro:locale` cookie + reloads. // Grow the app to more languages by adding a code here + a // `src/locales/.ts`. locales: ['en', 'de'] as const, defaultLocale: 'en' as const, }