Log Owl's browser adapter does not only catch errors in the browser but also allows you to collect information and metrics about your visitors. All events are reported to the Log Owl service. If you are using a self-hosted Log Owl service, you can easily configure the adapter to report to your own instance instead of Log Owl's managed service. This page will explain how to install and configure the adapter.
Framework agnostic: The adapter is designed to be framework agnostic.
Lightweight: The entire adapter is only 8kb and is hosted on a CDN.
Cross-browser compatibility: Great compatibility including IE11.
Easy setup: Install and configure the adapter in just a minute.
Add the script to the header of your website or web application.
To initialize the adapter with your desired configuration, you need to pass the configuration object to the
The ticket is the only mandatory information. Each service has a unique ticket and all events sent with this ticket will be attached to the corresponding service. The ticket can be found in your service on the
endpoint property to connect to your individual Log Owl instance at a given address. Please notice that the
endpoint property will be preferred to the
By default, Log Owl does not store the clients IP address. Keeping track of the IP address can be enabled with the option
Badges contain individual information that will be attached to the reported error. A badge must be of type string. You can add up to 80 badges. The key of the badge can have up to 100 characters while the value can have up to 200 characters. If these limits are exceeded, the event will not be processed.
Custom element IDs
The adapter tracks which elements the user has clicked before an error occurred. Among other information about the elements, it tracks the element's ID. Alternatively, you can set a custom element ID, which helps you identify the clicked elements.
To test if everything works you can just try to execute an undefined function like so.
Emitting errors manually
You can emit errors manually to build your own error handling logic.