UNPKG

@critters/next

Version:

Secure bug reporting library for Next.js applications

31 lines (30 loc) 809 B
import { ReportResult } from "./types"; /** * Core bug reporting functionality */ export declare class Critters { private static instance; private config; private constructor(); /** * Get the reporter instance */ static getInstance(): Critters; /** * Report a bug to the configured endpoint */ catch(error: Error | unknown, metadata?: Record<string, any>): Promise<ReportResult>; /** * Report a bug to the configured endpoint * @deprecated Use catch() instead */ reportBug(error: Error | unknown, metadata?: Record<string, any>): Promise<ReportResult>; /** * Create a bug report from an error */ private createBugReport; /** * Send a bug report to the configured endpoint */ private sendBugReport; }