Skip to main content
Browser monitoring is a beta AppSignal Labs feature. The @appsignal/browser package is published under the beta tag on npm, and its configuration and API may still change between beta releases. Share feedback in our Discord community.
@appsignal/browser replaces @appsignal/javascript, its framework integrations, and its plugin packages. This guide maps the old API onto the new one. @appsignal/javascript continues to work and keeps reporting to your existing error lists. New features only land in @appsignal/browser, so migrate when you want breadcrumbs without plugins, web vitals, or the Browser views.

What changes

One package instead of several. Error tracking, breadcrumbs, and web vitals are all in @appsignal/browser. The plugin packages and framework integration packages have no equivalent, because their functionality is either built in or no longer needed. Functions instead of an instance. There is no client object to create, pass around, or hand to a component. You call init() once and import the functions you need wherever you need them. Uncaught errors are reported without asking. @appsignal/plugin-window-events existed because you had to opt in to them. They are on by default now. Noise from browser extensions is dealt with by throwing away errors from scripts on other domains, and by beforeError, rather than by turning the whole category off. Errors report to the browser namespace. @appsignal/javascript reported to frontend, and there is no namespace option any more. Errors from the new package appear in the Browser section of your application rather than in your existing front-end error list. Existing incidents in the frontend namespace stay where they are.
Notification settings are configured per namespace, so the ones you set up for frontend do not apply to browser. Set them up again after migrating, or front-end errors will arrive without notifying anyone.
Your existing frontend incidents keep their assignees, states, and severities. Errors from the new package arrive as new issues in the browser namespace, so they start unassigned, the same as any error AppSignal has not seen before. No spans, decorators, or overrides. The span API and its hooks are gone. Set tags for every error with setTags(), pass context for a single error as the second argument to captureError(), and remove sensitive text in beforeError and beforeBreadcrumb.

Configuration

Before:
After:
Uncaught exceptions, console breadcrumbs, and network breadcrumbs are all covered by that single call.

Methods

appsignal.wrap() ran your code, reported anything it threw, and gave you back a promise that rejects with the same error, so you handled it in a try/catch or a .catch(). The direct replacement makes both halves explicit:

Framework integrations

The React error boundary changes shape:
The component name is detected from the React component stack, so there is no action prop to set.

Steps to migrate

  1. Install @appsignal/browser@beta and remove @appsignal/javascript along with every @appsignal/plugin-* and framework integration package.
  2. Replace your new Appsignal({ ... }) call with init({ ... }), using the configuration table in this guide. Add endpoint and active.
  3. Replace sendError with captureError, and wrap with try/catch.
  4. Move ignoreErrors patterns, decorators, and overrides into beforeError and beforeBreadcrumb.
  5. Call setRouteTemplate() on each router navigation.
  6. Swap the React error boundary import, if you use one.
  7. Set up notification settings for the browser namespace.
  8. Deploy, then confirm errors and web vitals arrive in the Browser section of your application.
Sourcemaps need no change. They are still matched on the revision string, which appVersion now supplies.