I’ve been using Sentry for logging errors in both WeWeb and Xano, and it’s been working pretty smoothly.
I created a global workflow that runs on app load (before fetching collections) and placed the following code in a JS block to capture and send all errors to Sentry, including Xano errors. It doesn’t require any custom API endpoints and is relatively easy to configure.
wwLib.getFrontWindow().axios.interceptors.response.use(
response => response,
error => {
// Capture all errors in Sentry
Sentry.captureException(error);
// Propagate the error to the rest of your error handling logic
return Promise.reject(error);
}
);
Hey @ericp! I actually haven’t looked into source maps yet—just set up Sentry for basic error tracking in WeWeb for now. It’s already been super helpful, even without digging into the deeper configuration. Would love to hear how it goes if you manage to set it up!
@Alchuu thank you for sharing this. I have added the JS code block shared above.
Question: How would Sentry know the logs are associated with my id or how will the data show up in my dashboard?
This ensures Sentry is available globally when the app loads.
Note: I’m not 100% sure this is the exact version I used — it might have changed slightly since I’m no longer using Sentry. I ended up building a custom solution.