Skip to content

Commit 1c29b87

Browse files
author
Sébastien Henau
committed
Merge branch 'feature/dependencies-update' into feature/tsdown-migration
2 parents f53687a + c86db63 commit 1c29b87

File tree

2 files changed

+16
-102
lines changed

2 files changed

+16
-102
lines changed

.claude/CLAUDE.md

Lines changed: 16 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -138,61 +138,17 @@ Before building new features, clean up the repo to make it a solid foundation. K
138138
**Goal:** Make Flare's JavaScript error tracking good enough to stand on its own — not just an add-on for Laravel/PHP
139139
users, but a worthy error tracker for JavaScript-only projects.
140140

141-
The frontend error monitoring is currently barebones. We need to research competitors (Sentry, PostHog, etc.), identify
142-
gaps, and ship improvements as a series of projects. Each project gets a release and an announcement post.
143-
144-
## Research & discovery
145-
146-
- [x] Research Sentry — features, DX, SDK capabilities, what they do well
147-
- [x] Research PostHog — error tracking features, session replay, context collection
148-
- [x] Research other competitors (Bugsnag, Rollbar, LogRocket, Datadog RUM, New Relic, Raygun, Highlight.io)
149-
- [x] Audit current Flare JS client capabilities in detail
150-
- [x] Compile findings: what are we missing? What's table stakes vs. differentiators?
151-
- [x] Organize findings + idea list into concrete projects with priorities
152-
153-
## Competitive research findings
154-
155-
### What every competitor has (table stakes we're missing)
156-
157-
| Feature | Sentry | Bugsnag | Rollbar | Flare |
158-
|---|---|---|---|---|
159-
| **Automatic breadcrumbs** (console, clicks, navigation, network) | Yes | Yes (best-in-class) | Yes ("telemetry") | Manual "glows" only |
160-
| **User identification API** (`setUser()`) | Yes | Yes | Yes | None |
161-
| **Device/browser/OS context** (parsed from UA) | Yes | Yes | Yes | Raw UA string only |
162-
| **Sampling / rate limiting** | Yes | Yes | Yes (`itemsPerMinute`) | None |
163-
| **addEventListener** (robust error capture) | Yes | Yes | Yes | Fragile `window.onerror =` assignment |
164-
| **Error deduplication** | Yes | Yes | Yes | None |
165-
| **Release/version tracking** | Yes | Yes | Yes | Only `sourcemapVersion` for sourcemaps |
166-
| **ignoreErrors / URL filtering** | Yes | Yes | Yes | Must implement manually in hooks |
167-
| **Error cause chaining** (`error.cause`) | Yes | Yes | No | None |
168-
| **Retry logic** for report submission | Yes | Yes | Yes | None (single fetch, lost on failure) |
169-
| **React Error Boundary with fallback UI** | Yes | Yes | Yes | No fallback, no getDerivedStateFromError |
170-
| **Multiple sourcemap upload tools** | Vite/Webpack/Rollup/esbuild/CLI | CLI + Webpack | CLI + Webpack | Vite only |
171-
172-
### What differentiates the leaders
173-
174-
| Feature | Leader | Notes |
175-
|---|---|---|
176-
| Session replay linked to errors | LogRocket, Sentry, PostHog | Watch what user did before crash |
177-
| Backend trace correlation | Datadog, New Relic | Link frontend error to backend span |
178-
| Stability/crash-free scores | Bugsnag | Session-based release health tracking |
179-
| Feature flag context | Bugsnag, PostHog, Datadog | Which flag variant caused the regression? |
180-
| State management integration | LogRocket | Redux/Vuex snapshots at time of error |
181-
| Rage/dead click detection | LogRocket, Datadog | User frustration signals |
182-
| Performance monitoring / Web Vitals | Sentry, Datadog, New Relic | Tracing + Core Web Vitals |
183-
| `guess_uncaught_frames` | Rollbar | Reconstruct missing stack frames heuristically |
184-
| Plugin/integration architecture | Sentry, Bugsnag | Tree-shakeable, modular, extensible |
185-
| Tunnel / ad blocker bypass | Sentry | Proxy events through your own server |
186-
187-
### Flare's existing unique strengths
188-
189-
- **Solution providers** — no competitor has programmatic "here's how to fix this" suggestions
190-
- **Tiny bundle**~3-5KB gzipped vs Sentry's ~22KB+ core
141+
The frontend error monitoring is currently barebones. We need to identify gaps and ship improvements as a series of projects. Each project gets a release and an announcement post.
142+
143+
## Flare's existing strengths
144+
145+
- **Solution providers** — programmatic "here's how to fix this" suggestions
146+
- **Tiny bundle**~3-5KB gzipped
191147
- **Laravel/PHP ecosystem** — deep integration with the most popular PHP framework
192-
- **Vite-first** — modern build tool support (most competitors still lead with Webpack)
148+
- **Vite-first** — modern build tool support
193149
- **Clean two-hook system**`beforeEvaluate` (filter errors) + `beforeSubmit` (modify reports)
194150

195-
### Current gaps in Flare (detailed)
151+
## Current gaps in Flare (detailed)
196152

197153
**Context collection** — only captures URL, user agent (raw string), referrer, readyState, cookies, query params. Missing: browser name/version, OS, device type, screen size, viewport, locale, timezone, online/offline status, memory, connection info.
198154

@@ -202,7 +158,7 @@ gaps, and ship improvements as a series of projects. Each project gets a release
202158

203159
**Networking** — single `fetch()` POST per error. No retry, no offline queue, no rate limiting, no batching, no `sendBeacon()` for unload, no request timeout.
204160

205-
**React** (`@flareapp/react`) — captures component stack string only. Missing: fallback UI (`getDerivedStateFromError`), component props, component name, onError/onReset callbacks, React Router integration, Redux/Zustand state.
161+
**React** (`@flareapp/react`) — captures component stack string only. Missing: fallback UI (`getDerivedStateFromError`), component props, component name, onError/onReset callbacks, React Router integration, state management integration.
206162

207163
**Vue** (`@flareapp/vue`) — captures component name + info string. Missing: component props, Vue Router context, Pinia/Vuex state, component tree. Written in plain JS (no TypeScript).
208164

@@ -212,9 +168,9 @@ gaps, and ship improvements as a series of projects. Each project gets a release
212168

213169
## Roadmap: organized into projects
214170

215-
### Project 1: Core SDK hardening (table stakes)
171+
### Project 1: Core SDK hardening
216172

217-
Make `@flareapp/js` robust and feature-complete with what every competitor ships. This is the foundation everything else builds on.
173+
Make `@flareapp/js` robust and feature-complete. This is the foundation everything else builds on.
218174

219175
- [ ] Switch from `window.onerror =` to `addEventListener('error')` / `addEventListener('unhandledrejection')` for robustness
220176
- [ ] Automatic breadcrumbs: console output interception (`console.log/warn/error/info/debug`)
@@ -240,7 +196,7 @@ Make `@flareapp/js` robust and feature-complete with what every competitor ships
240196

241197
### Project 2: Enhanced React package
242198

243-
Make `@flareapp/react` competitive with Sentry's React integration.
199+
Make `@flareapp/react` a full-featured React error tracking integration.
244200

245201
- [ ] Fallback UI: implement `getDerivedStateFromError` so the boundary can render a fallback component
246202
- [ ] Configurable fallback: `<FlareErrorBoundary fallback={<ErrorPage />}>` or render prop `fallback={(error, reset) => ...}`
@@ -253,7 +209,7 @@ Make `@flareapp/react` competitive with Sentry's React integration.
253209

254210
### Project 3: Enhanced Vue package
255211

256-
Make `@flareapp/vue` competitive with Sentry's Vue integration.
212+
Make `@flareapp/vue` a full-featured Vue error tracking integration.
257213

258214
- [ ] Rewrite in TypeScript (currently plain JS)
259215
- [ ] Capture component props (configurable: `attachProps: true/false`)
@@ -312,13 +268,11 @@ Verify and ensure Flare works beyond the browser.
312268

313269
## Future considerations (not yet planned as projects)
314270

315-
These are features the leading competitors have but that may be out of scope for now:
316-
317-
- **Session replay** — would be a major undertaking (PostHog, Sentry, LogRocket all have this)
271+
- **Session replay** — would be a major undertaking
318272
- **Performance monitoring / Web Vitals** — could be a lightweight add-on
319-
- **Distributed tracing** — connecting frontend errors to backend spans (Datadog/New Relic territory)
273+
- **Distributed tracing** — connecting frontend errors to backend spans
320274
- **Feature flag integration** — linking errors to active feature flags
321275
- **Tunnel / ad blocker bypass** — proxy events through the user's own server
322-
- **Plugin/integration architecture** — modular system like Sentry's integrations (would require significant refactoring)
276+
- **Plugin/integration architecture** — modular, tree-shakeable, extensible system (would require significant refactoring)
323277
- **Offline event queuing** — persist unsent events in localStorage/IndexedDB
324278
- **Rage/dead click detection** — user frustration signals without explicit errors

.claude/skills/research/SKILL.md

Lines changed: 0 additions & 40 deletions
This file was deleted.

0 commit comments

Comments
 (0)