5b38ddc41d1f9b8209cf4530e694280620e69989
apps/web (@sentry/nextjs): - sentry.client.config.ts / sentry.server.config.ts / sentry.edge.config.ts initialize Sentry only when NEXT_PUBLIC_SENTRY_DSN (or SENTRY_DSN on the server) is set; tracesSampleRate 0.1 - next.config.mjs wraps the existing config with withSentryConfig only when a DSN is present; source-map upload stays disabled until SENTRY_AUTH_TOKEN is provided - .env.example documents NEXT_PUBLIC_SENTRY_DSN and the optional auth token apps/api (@sentry/node): - src/lib/sentry.ts initializes Sentry at module load when SENTRY_DSN is set - server.ts imports sentry.ts as the very first side-effect so early-boot errors (env validation, plugin registration) reach Sentry - env schema gains optional SENTRY_DSN (URL) - app.ts registers an errorHandler that captures the exception with the authenticated user when SENTRY_DSN is set; logs and re-sends as before Build-time housekeeping: - profile route: targetDate ?? null on create to satisfy Prisma's input shape under exactOptionalPropertyTypes - profile form: useForm receives defaultValues only when initial is provided (spread instead of `defaultValues: undefined`); Field error prop typed `string | undefined` for exactOptionalPropertyTypes Without a DSN both apps run unchanged (Sentry is inert). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
KetoPath
Web app responsive multi-utente per la gestione personalizzata di chetogenica e digiuno intermittente.
Vedi
CLAUDE.mdper le convenzioni di progetto edocs/PRD_KetoPath.docxper il PRD completo.
Prerequisiti
- Node.js
>=20.11(vedi.nvmrc) - pnpm
>=9(corepack enable && corepack prepare pnpm@latest --activate)
Getting started
pnpm install
pnpm typecheck
pnpm lint
pnpm format:check
Struttura del monorepo
apps/
web/ # Next.js 14 frontend (da scaffoldare)
api/ # Fastify backend (da scaffoldare)
packages/
shared/ # Tipi e utility di dominio
ui/ # Componenti UI riusabili
db/ # Prisma client (da scaffoldare)
tsconfig/ # tsconfig presets condivisi
eslint-config/ # ESLint config condivisa
docs/
PRD_KetoPath.docx
Script disponibili
pnpm dev— avvia tutte le app in parallelopnpm dev:web/pnpm dev:api— avvia singola apppnpm build— build di produzionepnpm lint/pnpm lint:fix— ESLintpnpm format/pnpm format:check— Prettierpnpm typecheck—tsc -bsu tutto il monorepopnpm test— Vitest (unit test)pnpm test:e2e— Playwright (E2E)
Languages
TypeScript
97.3%
CSS
1.7%
JavaScript
1%