Skip to content

Commit 141bb42

Browse files
authored
Merge pull request #25 from ACHultman/next15
Upgrade to Next.js 15
2 parents af1e9c9 + 98b9ce0 commit 141bb42

14 files changed

+7498
-2422
lines changed

instrumentation.ts

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import * as Sentry from '@sentry/nextjs';
2+
3+
const SENTRY_DSN = process.env.SENTRY_DSN || process.env.NEXT_PUBLIC_SENTRY_DSN;
4+
5+
export async function register() {
6+
if (process.env.NEXT_RUNTIME === 'nodejs') {
7+
Sentry.init({
8+
dsn:
9+
SENTRY_DSN ||
10+
'https://98885e1818014bf197142a70aeb117e5@o4504819206389760.ingest.sentry.io/4504819208093696',
11+
tracesSampleRate: 1.0,
12+
});
13+
}
14+
15+
if (process.env.NEXT_RUNTIME === 'edge') {
16+
Sentry.init({
17+
dsn:
18+
SENTRY_DSN ||
19+
'https://98885e1818014bf197142a70aeb117e5@o4504819206389760.ingest.sentry.io/4504819208093696',
20+
tracesSampleRate: 1.0,
21+
});
22+
}
23+
}

next.config.js

-38
This file was deleted.

next.config.ts

+102
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
const { withSentryConfig } = require('@sentry/nextjs');
2+
3+
module.exports = {
4+
serverExternalPackages: ['next-seo'],
5+
images: {
6+
remotePatterns: [
7+
{
8+
protocol: 'https',
9+
hostname: 'media.wiley.com',
10+
port: '',
11+
pathname: '/**',
12+
},
13+
{
14+
protocol: 'https',
15+
hostname: 'images.wiley.com',
16+
port: '',
17+
pathname: '/**',
18+
},
19+
{
20+
protocol: 'https',
21+
hostname: 'images.wiley.com.au',
22+
port: '',
23+
pathname: '/**',
24+
},
25+
{
26+
protocol: 'https',
27+
hostname: 'images.wiley.com.au.s3.amazonaws.com',
28+
port: '',
29+
pathname: '/**',
30+
},
31+
{
32+
protocol: 'https',
33+
hostname: 'learning.oreilly.com',
34+
port: '',
35+
pathname: '/**',
36+
},
37+
{
38+
protocol: 'https',
39+
hostname: 'reactjs.org',
40+
port: '',
41+
pathname: '/**',
42+
},
43+
{
44+
protocol: 'https',
45+
hostname: 'easings.net',
46+
port: '',
47+
pathname: '/**',
48+
},
49+
{
50+
protocol: 'https',
51+
hostname: 'github.com',
52+
port: '',
53+
pathname: '/**',
54+
},
55+
{
56+
protocol: 'https',
57+
hostname: 'repository-images.githubusercontent.com',
58+
port: '',
59+
pathname: '/**',
60+
},
61+
{
62+
protocol: 'https',
63+
hostname: 'projects-raspberry.com',
64+
port: '',
65+
pathname: '/**',
66+
},
67+
{
68+
protocol: 'https',
69+
hostname: 'blog.tensorflow.org',
70+
port: '',
71+
pathname: '/**',
72+
},
73+
{
74+
protocol: 'https',
75+
hostname: 'blogger.googleusercontent.com',
76+
port: '',
77+
pathname: '/**',
78+
},
79+
{
80+
protocol: 'https',
81+
hostname: 'storage.googleapis.com',
82+
port: '',
83+
pathname: '/**',
84+
},
85+
{
86+
protocol: 'https',
87+
hostname: 'images-na.ssl-images-amazon.com',
88+
port: '',
89+
pathname: '/**',
90+
},
91+
],
92+
},
93+
compiler: {
94+
emotion: true,
95+
},
96+
};
97+
98+
module.exports = withSentryConfig(
99+
module.exports,
100+
{ silent: true },
101+
{ hideSourcemaps: true }
102+
);

0 commit comments

Comments
 (0)