1+ const { withSentryConfig } = require ( '@sentry/nextjs' ) ;
2+
13// eslint-disable-next-line
24const withBundleAnalyzer = require ( '@next/bundle-analyzer' ) ( {
35 enabled : process . env . ANALYZE === 'true' ,
@@ -8,53 +10,86 @@ if (process.env.NEXT_PUBLIC_ENABLE_GOVERNANCE === 'true') pageExtensions.push('g
810if ( process . env . NEXT_PUBLIC_ENABLE_STAKING === 'true' ) pageExtensions . push ( 'staking.tsx' ) ;
911
1012/** @type {import('next').NextConfig } */
11- module . exports = withBundleAnalyzer ( {
12- webpack ( config ) {
13- config . module . rules . push ( {
14- test : / \. s v g $ / i,
15- issuer : / \. [ j t ] s x ? $ / ,
16- use : [
17- {
18- loader : '@svgr/webpack' ,
19- options : {
20- svgoConfig : {
21- plugins : [ 'prefixIds' ] ,
13+ module . exports = withSentryConfig (
14+ withBundleAnalyzer ( {
15+ webpack ( config ) {
16+ config . module . rules . push ( {
17+ test : / \. s v g $ / i,
18+ issuer : / \. [ j t ] s x ? $ / ,
19+ use : [
20+ {
21+ loader : '@svgr/webpack' ,
22+ options : {
23+ svgoConfig : {
24+ plugins : [ 'prefixIds' ] ,
25+ } ,
2226 } ,
2327 } ,
24- } ,
25- ] ,
26- } ) ;
27- config . experiments = {
28- topLevelAwait : true ,
29- layers : true , // added for next api routes rpc proxy
30- } ;
31- config . resolve . fallback = { fs : false , net : false , tls : false } ;
32- return config ;
33- } ,
34- reactStrictMode : true ,
35- // assetPrefix: "./",
36- trailingSlash : true ,
37- pageExtensions,
38- // NOTE: Needed for SAFE testing locally
39- // async headers() {
40- // return [
41- // {
42- // source: '/manifest.json',
43- // headers: [
44- // {
45- // key: 'Access-Control-Allow-Origin',
46- // value: '*',
47- // },
48- // {
49- // key: 'Access-Control-Allow-Methods',
50- // value: 'GET',
51- // },
52- // {
53- // key: 'Access-Control-Allow-Headers',
54- // value: 'X-Requested-With, content-type, Authorization',
55- // },
56- // ],
57- // },
58- // ];
59- // },
60- } ) ;
28+ ] ,
29+ } ) ;
30+ config . experiments = {
31+ topLevelAwait : true ,
32+ layers : true , // added for next api routes rpc proxy
33+ } ;
34+ config . resolve . fallback = { fs : false , net : false , tls : false } ;
35+ return config ;
36+ } ,
37+ reactStrictMode : true ,
38+ // assetPrefix: "./",
39+ trailingSlash : true ,
40+ pageExtensions,
41+ // NOTE: Needed for SAFE testing locally
42+ // async headers() {
43+ // return [
44+ // {
45+ // source: '/manifest.json',
46+ // headers: [
47+ // {
48+ // key: 'Access-Control-Allow-Origin',
49+ // value: '*',
50+ // },
51+ // {
52+ // key: 'Access-Control-Allow-Methods',
53+ // value: 'GET',
54+ // },
55+ // {
56+ // key: 'Access-Control-Allow-Headers',
57+ // value: 'X-Requested-With, content-type, Authorization',
58+ // },
59+ // ],
60+ // },
61+ // ];
62+ // },
63+ } ) ,
64+ {
65+ // For all available options, see:
66+ // https://www.npmjs.com/package/@sentry /webpack-plugin#options
67+
68+ org : 'avara-ex' ,
69+ project : 'aave-v3' ,
70+
71+ // Only print logs for uploading source maps in CI
72+ silent : ! process . env . CI ,
73+
74+ // For all available options, see:
75+ // https://docs.sentry.io/platforms/javascript/guides/nextjs/manual-setup/
76+
77+ // Upload a larger set of source maps for prettier stack traces (increases build time)
78+ widenClientFileUpload : true ,
79+
80+ // Route browser requests to Sentry through a Next.js rewrite to circumvent ad-blockers.
81+ // This can increase your server load as well as your hosting bill.
82+ // Note: Check that the configured route will not match with your Next.js middleware, otherwise reporting of client-
83+ // side errors will fail.
84+ tunnelRoute : '/monitoring' ,
85+
86+ // Automatically tree-shake Sentry logger statements to reduce bundle size
87+ disableLogger : true ,
88+
89+ // Enables automatic instrumentation of Vercel Cron Monitors. (Does not yet work with App Router route handlers.)
90+ // See the following for more information:
91+ // https://docs.sentry.io/product/crons/
92+ // https://vercel.com/docs/cron-jobs
93+ automaticVercelMonitors : true ,
94+ }
95+ ) ;
0 commit comments