Files
HealthLog/next.config.ts
T
Marc-André Bombeck 2d111fcb24 chore(release): v1.4.28
Bug-fix and consistency follow-through after the v1.4.27 mobile sweep.
The headline is a tighter dashboard and insights surface: six widgets
retire from code entirely (GLP-1 tile, dashboard `<DrugLevelChart>`
mount, GLP-1 detail-page intake history + inventory, the
`<InsightAdvisorCard>` block and its regeneration affordance, the
weekly-report route), four broken edges close (workout-edit duplicate-
timestamp 409, BD-Zielbereich tile rebuilt on the shared
`<TrendCard>` primitive, `/insights/puls` chart timeout fallback,
sticky tab-strip scroll lock), and one consistency contract lands per
maintainer directive: every medication-list row, every medication-
detail section header, every trend tile, every Coach launch glyph,
every chart-height contract reads on one shape. The HealthScore card
grows to fill its column, gains an accessible `?` tooltip explaining
the delta, and drops the placeholder "Wochenbericht erstellen"
button. iOS contracts are intact; the only `/api/*` evolution is
additive (the `aggregate=monthly` grain on `/api/measurements` and an
internal-only `/api/internal/web-vitals` beacon route).
2026-05-16 03:17:00 +02:00

41 lines
1.3 KiB
TypeScript

import type { NextConfig } from "next";
import bundleAnalyzer from "@next/bundle-analyzer";
const nextConfig: NextConfig = {
output: "standalone",
poweredByHeader: false,
serverExternalPackages: [
"@prisma/client",
"pg-boss",
"@prisma/adapter-pg",
"pg",
],
// v1.4.25 Fix-G — `src/lib/ai/prompts/safety-contracts.ts` reads its
// sibling YAML files at runtime via `__dirname + readFileSync`. The
// standalone bundler ships the JS but not the YAML, so the build
// crashed during page-data collection with ENOENT once the Turbopack
// chunking-error layer was cleared. Telling Next to trace the YAML
// files explicitly keeps them in the runtime image alongside the
// bundled module.
outputFileTracingIncludes: {
"*": ["./src/lib/ai/prompts/safety-contracts.*.yaml"],
},
experimental: {
optimizePackageImports: ["recharts", "lucide-react"],
},
};
/**
* v1.4.28 R3d — opt-in bundle analyzer behind `ANALYZE=1`.
*
* `pnpm analyze` (defined in `package.json`) sets the env var and
* runs `next build`; the analyzer writes static HTML reports to
* `.next/analyze/*.html`. The wrapper is a no-op when the env var is
* unset so the regular `pnpm build` pipeline pays nothing.
*/
const withBundleAnalyzer = bundleAnalyzer({
enabled: process.env.ANALYZE === "1",
});
export default withBundleAnalyzer(nextConfig);