fix: upgrade to nextjs 16 (#888)

* Upgrade to nextjs 16

* Update sentry config

* Force dynamic for health route

* Upgrade eslint config

* Upgrade jest

* Move types to dev dependencies

* Remove pages from tailwind config

* Replace img with next image
This commit is contained in:
Sergey Mankovsky
2026-02-27 17:18:03 +01:00
committed by GitHub
parent 7f9ce7f13a
commit f6cc03286b
20 changed files with 1077 additions and 916 deletions

View File

@@ -4,47 +4,20 @@ const nextConfig = {
env: {
IS_CI: process.env.IS_CI,
},
experimental: {
optimizePackageImports: ["@chakra-ui/react"],
},
};
module.exports = nextConfig;
// Injected content via Sentry wizard below
const { withSentryConfig } = require("@sentry/nextjs");
module.exports = withSentryConfig(
module.exports,
{
// For all available options, see:
// https://github.com/getsentry/sentry-webpack-plugin#options
// Suppresses source map uploading logs during build
silent: true,
org: "monadical",
project: "reflector-www",
module.exports = withSentryConfig(nextConfig, {
silent: true,
org: "monadical",
project: "reflector-www",
widenClientFileUpload: true,
tunnelRoute: "/monitoring",
bundleSizeOptimizations: {
excludeDebugStatements: true,
},
{
// For all available options, see:
// https://docs.sentry.io/platforms/javascript/guides/nextjs/manual-setup/
// Upload a larger set of source maps for prettier stack traces (increases build time)
widenClientFileUpload: true,
// Transpiles SDK to be compatible with IE11 (increases bundle size)
transpileClientSDK: true,
// Routes browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers (increases server load)
tunnelRoute: "/monitoring",
// Hides source maps from generated client bundles
hideSourceMaps: true,
// Automatically tree-shake Sentry logger statements to reduce bundle size
disableLogger: true,
experimental: {
optimizePackageImports: ["@chakra-ui/react"],
},
},
);
});