Skip to content

Commit f81f035

Browse files
committed
rm sentry
1 parent 34d91b4 commit f81f035

File tree

8 files changed

+40
-55
lines changed

8 files changed

+40
-55
lines changed

app/global-error.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@
33
import 'prism-sentry/index.css';
44

55
import {useEffect} from 'react';
6-
import * as Sentry from '@sentry/nextjs';
6+
// import * as Sentry from '@sentry/nextjs';
77
import Error from 'next/error';
88

99
export default function GlobalError({error}) {
1010
useEffect(() => {
11-
Sentry.captureException(error);
11+
// Sentry.captureException(error);
1212
}, [error]);
1313

1414
return (

next.config.js

Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const {redirects} = require('./redirects.js');
22

33
const {codecovNextJSWebpackPlugin} = require('@codecov/nextjs-webpack-plugin');
4-
const {withSentryConfig} = require('@sentry/nextjs');
4+
// const {withSentryConfig} = require('@sentry/nextjs');
55

66
const outputFileTracingExcludes = process.env.NEXT_PUBLIC_DEVELOPER_DOCS
77
? {
@@ -13,6 +13,8 @@ const outputFileTracingExcludes = process.env.NEXT_PUBLIC_DEVELOPER_DOCS
1313
'./apps/**/*',
1414
'develop-docs/**/*',
1515
'node_modules/@esbuild/darwin-arm64',
16+
'*.png',
17+
'*.gif',
1618
],
1719
'/platform-redirect': ['**/*.gif', 'public/mdx-images/**/*', '*.pdf'],
1820
'\\[\\[\\.\\.\\.path\\]\\]': [
@@ -33,7 +35,7 @@ if (
3335
}
3436

3537
/** @type {import('next').NextConfig} */
36-
const nextConfig = {
38+
module.exports = {
3739
pageExtensions: ['js', 'jsx', 'mdx', 'ts', 'tsx'],
3840
trailingSlash: true,
3941
serverExternalPackages: ['rehype-preset-minify'],
@@ -64,43 +66,43 @@ const nextConfig = {
6466
},
6567
};
6668

67-
module.exports = withSentryConfig(nextConfig, {
68-
org: 'sentry',
69-
project: process.env.NEXT_PUBLIC_DEVELOPER_DOCS ? 'develop-docs' : 'docs',
69+
// module.exports = withSentryConfig(nextConfig, {
70+
// org: 'sentry',
71+
// project: process.env.NEXT_PUBLIC_DEVELOPER_DOCS ? 'develop-docs' : 'docs',
7072

71-
// Suppresses source map uploading logs during build
72-
silent: !process.env.CI,
73+
// // Suppresses source map uploading logs during build
74+
// silent: !process.env.CI,
7375

74-
// Upload a larger set of source maps for prettier stack traces (increases build time)
75-
widenClientFileUpload: true,
76+
// // Upload a larger set of source maps for prettier stack traces (increases build time)
77+
// widenClientFileUpload: true,
7678

77-
// Transpiles SDK to be compatible with IE11 (increases bundle size)
78-
transpileClientSDK: true,
79+
// // Transpiles SDK to be compatible with IE11 (increases bundle size)
80+
// transpileClientSDK: true,
7981

80-
// Hides source maps from generated client bundles
81-
hideSourceMaps: true,
82+
// // Hides source maps from generated client bundles
83+
// hideSourceMaps: true,
8284

83-
// Automatically tree-shake Sentry logger statements to reduce bundle size
84-
disableLogger: true,
85+
// // Automatically tree-shake Sentry logger statements to reduce bundle size
86+
// disableLogger: true,
8587

86-
// Enables automatic instrumentation of Vercel Cron Monitors
87-
// See the following for more information:
88-
// https://docs.sentry.io/product/crons/
89-
// https://vercel.com/docs/cron-jobs
90-
automaticVercelMonitors: true,
88+
// // Enables automatic instrumentation of Vercel Cron Monitors
89+
// // See the following for more information:
90+
// // https://docs.sentry.io/product/crons/
91+
// // https://vercel.com/docs/cron-jobs
92+
// automaticVercelMonitors: true,
9193

92-
reactComponentAnnotation: {
93-
enabled: true,
94-
},
94+
// reactComponentAnnotation: {
95+
// enabled: true,
96+
// },
9597

96-
unstable_sentryWebpackPluginOptions: {
97-
applicationKey: 'sentry-docs',
98-
},
98+
// unstable_sentryWebpackPluginOptions: {
99+
// applicationKey: 'sentry-docs',
100+
// },
99101

100-
_experimental: {
101-
thirdPartyOriginStackFrames: true,
102-
},
103-
});
102+
// _experimental: {
103+
// thirdPartyOriginStackFrames: true,
104+
// },
105+
// });
104106

105107
process.on('warning', warning => {
106108
if (warning.code === 'DEP0040') {

src/components/codeHighlights/codeHighlights.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
import {Children, cloneElement, ReactElement, useEffect, useRef, useState} from 'react';
44
import {Check, Clipboard} from 'react-feather';
55
import styled from '@emotion/styled';
6-
import * as Sentry from '@sentry/nextjs';
76

7+
// import * as Sentry from '@sentry/nextjs';
88
import {cleanCodeSnippet, useCleanSnippetInClipboard} from '../codeBlock';
99

1010
type ChildrenItem = ReturnType<typeof Children.toArray>[number] | React.ReactNode;
@@ -103,7 +103,7 @@ export function HighlightBlock({
103103
setCopied(true);
104104
setTimeout(() => setCopied(false), 1200);
105105
} catch (error) {
106-
Sentry.captureException(error);
106+
// Sentry.captureException(error);
107107
setCopied(false);
108108
}
109109
}

src/components/expandable/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22

33
import {ReactNode, useCallback, useEffect, useRef, useState} from 'react';
44
import {ChevronDownIcon, ChevronRightIcon} from '@radix-ui/react-icons';
5-
import * as Sentry from '@sentry/nextjs';
65

6+
// import * as Sentry from '@sentry/nextjs';
77
// explicitly not usig CSS modules here
88
// because there's some prerendered content that depends on these exact class names
99
import '../callout/styles.scss';
@@ -106,7 +106,7 @@ export function Expandable({
106106
setCopied(true);
107107
setTimeout(() => setCopied(false), 1200);
108108
} catch (error) {
109-
Sentry.captureException(error);
109+
// Sentry.captureException(error);
110110
setCopied(false);
111111
}
112112
},

src/components/search/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import {Fragment, useCallback, useEffect, useRef, useState} from 'react';
44
import {ArrowRightIcon} from '@radix-ui/react-icons';
55
import {Button} from '@radix-ui/themes';
6-
import {captureException} from '@sentry/nextjs';
6+
// import {captureException} from '@sentry/nextjs';
77
import {
88
Hit,
99
Result,
@@ -244,7 +244,7 @@ export function Search({
244244
positions: [position + 1],
245245
});
246246
} catch (error) {
247-
captureException(error);
247+
// captureException(error);
248248
}
249249
}, []);
250250

File renamed without changes.
File renamed without changes.

src/pages/_error.jsx

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)