API Reference
Error Monitoring
Getting Started
Welcome to Highlight
Integrations
Product Features
Session Replay
Tips
Menu
H.consumeError()
This method is used to send Highlight a custom error.
H.consumeError(error: Error, message?: string, payload: { [key: string]: string }) => void;
error Required
A Javascript error that you have created or have access to.
message
An additional message you'd like to add to the error to give the error more context.
payload
Additional metadata that you'd like to attach to the error to give the error more context.
Example
// error is provided to you from your Javascript framework or something like https://github.com/stacktracejs/stacktrace.js/ H.consumeError(error, 'Error in Highlight custom boundary!', { component: 'JustThroughAnError.tsx', })