Errors

Galacha captures unhandled errors and promise rejections out of the box. On React Native it also catches native crashes. Each error is anchored to the exact moment in the session replay, so you scrub to the frame and see what the user was doing when it broke.

What's captured automatically

HookWhat it catchesPlatform
window.onerrorSynchronous JS exceptionsWeb
window.onunhandledrejectionRejected promises with no catchWeb
ErrorUtils.setGlobalHandlerJS engine errorsReact Native
Thread.setDefaultUncaughtExceptionHandlerNative Kotlin crashesReact Native (Android)
NSSetUncaughtExceptionHandlerNative Swift crashesReact Native (iOS)

Capture is on by default. To turn it off:

Galacha.init({
  projectKey: "your_project_key",
  captureErrors: false,
});

Adding context to caught errors (React Native only)

There is no captureError() method on any platform . the SDK auto-captures everything unhandled. On React Native, Galacha.track() is available for custom events, so you can annotate a handled error before re-throwing:

import Galacha from "@galacha/react-native";
 
try {
  await purchase();
} catch (err) {
  Galacha.track("purchase_failed", {
    message: err.message,
    stage: "checkout",
    cartSize: cart.items.length,
  });
  throw err; // let it bubble to the auto-capture
}

If you swallow the error (don't re-throw), only the track() event reaches the dashboard . usually what you want for non-critical failures.

On web, there is no public Galacha.track() method. The web SDK's public API is init, identify, and stop . full stop. Handled errors on web either need to be re-thrown (so auto-capture picks them up) or logged through your own observability pipeline.

Where errors show up in the dashboard

PlaceWhat you see
Session replay timelineA red marker at the exact moment the error fired. Click to jump to the frame.
Top Errors widgetOn the project dashboard, grouped by message with 7-day counts.
Errors pageFull list filtered by project + time range, with a stack preview.

Source maps

Not currently supported. Minified web bundles will show obfuscated stacks in the dashboard. Keep a non-minified build around for debugging, or email kelvin@galacha.me if source-map upload would unblock you . it's on the roadmap.