'use client' // Error components must be Client Components import { useEffect, useState } from 'react' export default function Error({ error, }: { error: Error & { digest?: string } reset: () => void }) { const [showFull, setShowFull] = useState(false) useEffect(() => { // Log the error to an error reporting service console.error(error) }, [error]) return ( <>

Oops! Unexpected error occurred.

Something went wrong. Try to{' '} {' '} or
feel free to{' '} contact us {' '} if the problem persists.

Error: {error.message}
                {showFull ? error.stack : error.stack?.slice(0, 200)}
              
) }