Skip to content

Instantly share code, notes, and snippets.

View thucpn's full-sized avatar
🏠
Working from home

Thuc Pham thucpn

🏠
Working from home
  • Ho Chi Minh City, Vietnam
View GitHub Profile
@Froelund
Froelund / _error.tsx
Last active November 30, 2023 04:35
Next.js Typescript error reporting
import { captureException, flush } from '@sentry/nextjs';
import NextErrorComponent from 'next/error';
import type { ErrorProps } from 'next/error';
import type { NextPage } from 'next';
interface AppErrorProps extends ErrorProps {
err?: Error;
hasGetInitialPropsRun?: boolean;
}