Merged in feat/sentry (pull request #1089)
This commit is contained in:
committed by
Joakim Jäderberg
parent
e0c5b59860
commit
3982b1ba56
@@ -1,5 +1,8 @@
|
||||
"use client"
|
||||
|
||||
import * as Sentry from "@sentry/nextjs"
|
||||
import { useEffect } from "react"
|
||||
|
||||
import styles from "./global-error.module.css"
|
||||
|
||||
export default function GlobalError({
|
||||
@@ -8,6 +11,11 @@ export default function GlobalError({
|
||||
error: Error & { digest?: string }
|
||||
}) {
|
||||
console.log({ global_error: error })
|
||||
|
||||
useEffect(() => {
|
||||
Sentry.captureException(error)
|
||||
}, [error])
|
||||
|
||||
return (
|
||||
<html>
|
||||
<body>
|
||||
|
||||
Reference in New Issue
Block a user