Skip to content

Commit

Permalink
Add button to test Sentry
Browse files Browse the repository at this point in the history
  • Loading branch information
rakyi committed Jan 14, 2025
1 parent d67fc63 commit 914e4f8
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
8 changes: 8 additions & 0 deletions site/gdocs/pages/AboutPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,14 @@ import Footnotes from "../components/Footnotes.js"
export default function AboutPage({ content, slug }: OwidGdocAboutInterface) {
return (
<main className="about-page centered-article-container grid grid-cols-12-full-width">
<button
className=""
onClick={() => {
throw new Error("Test Sentry error from site")
}}
>
Break the world
</button>
<h1 className="about-header col-start-2 col-end-limit display-2-semibold">
About
</h1>
Expand Down
5 changes: 5 additions & 0 deletions site/instrument.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ if (analyticsConsent && !isInIFrame()) {
replaysOnErrorSampleRate: 0,
}
}
console.log("sentryOpts", sentryOpts)

Check warning on line 30 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement

Check warning on line 30 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement
console.log("process.env", process.env)

Check warning on line 31 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement

Check warning on line 31 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement
console.log("analyticsConsent", analyticsConsent)

Check warning on line 32 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement

Check warning on line 32 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement
console.log("isInIFrame()", isInIFrame())

Check warning on line 33 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement

Check warning on line 33 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement
console.log("environment", environment)

Check warning on line 34 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement

Check warning on line 34 in site/instrument.ts

View workflow job for this annotation

GitHub Actions / eslint

Unexpected console statement
Sentry.init({
dsn: process.env.SENTRY_DSN,
environment,
Expand Down

0 comments on commit 914e4f8

Please sign in to comment.