Skip to content

Commit e2d00b2

Browse files
author
Sébastien Henau
committed
cleanup
1 parent 1be6807 commit e2d00b2

File tree

1 file changed

+0
-15
lines changed

1 file changed

+0
-15
lines changed

.claude/docs/research.md

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -92,21 +92,6 @@ Make `@flareapp/js` robust and feature-complete. This is the foundation everythi
9292

9393
- [ ] Switch from `window.onerror =` to `addEventListener('error')` / `addEventListener('unhandledrejection')` for
9494
robustness
95-
- Sentry uses `window.onerror` for specific reasons that don't apply here: their async loader needs to inspect
96-
`window.onerror` (can't introspect `addEventListener` listeners), they have years of cross-browser edge case
97-
coverage they don't want to risk, and they support downcompilation to ES5. Their maintainers acknowledge the
98-
functional difference is
99-
marginal. ([Discussion #5786](https://github.com/getsentry/sentry-javascript/discussions/5786))
100-
- `addEventListener` advantages: multiple handlers coexist (no silent overwrite by third-party scripts), catches
101-
resource load errors in capture phase, proper `ErrorEvent` object instead of decomposed args.
102-
- `window.onerror` advantage: handler is inspectable afterward (irrelevant for Flare).
103-
- Recommendation: switch to `addEventListener` — Flare targets ES2022, has no lazy loader pattern, and the
104-
current
105-
property-based approach is fragile in multi-script environments.
106-
- Sources:
107-
- https://github.com/getsentry/sentry-javascript/discussions/5786
108-
- https://github.com/getsentry/sentry-javascript/discussions/7542
109-
- https://blog.sentry.io/client-javascript-reporting-window-onerror/
11095
- [ ] Automatic breadcrumbs: console output interception (`console.log/warn/error/info/debug`)
11196
- [ ] Automatic breadcrumbs: DOM click tracking (element tag, CSS selector)
11297
- [ ] Automatic breadcrumbs: Navigation / History API changes (`pushState`, `replaceState`, `popstate`)

0 commit comments

Comments
 (0)