Files
web/app/[lang]/(live)/(protected)/my-pages/profile/@profile/error.tsx
2025-01-13 13:35:03 +01:00

21 lines
462 B
TypeScript

"use client"
import * as Sentry from "@sentry/nextjs"
import { useEffect } from "react"
import { useIntl } from "react-intl"
import type { ErrorPage } from "@/types/next/error"
export default function ProfileError({ error }: ErrorPage) {
const intl = useIntl()
useEffect(() => {
if (!error) return
console.error(error)
Sentry.captureException(error)
}, [error])
return <h1>{intl.formatMessage({ id: "Error happened, Profile" })}</h1>
}