firebench 0.1.0-alpha.3
firebench: ^0.1.0-alpha.3 copied to clipboard
Sentry-style automatic per-screen performance tracing for Flutter, reported to the free Firebase Performance backend.
Changelog #
All notable changes to this project are documented here. The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.1.0-alpha.3 - 2026-06-13 #
Fixed #
- A time-to-full-display report that arrived after the user navigated to the next screen could stamp that next screen's trace with the previous screen's load time. Display reporting is now strictly bound to the screen it was captured for: a late report on a screen the user already left is dropped, never reattributed.
Removed #
- Breaking: the singleton
Firebench.instance.reportFullyDisplayed(). It resolved the topmost screen at call time, which misattributed late reports. Capture aFirebenchDisplayviaFirebench.instance.currentDisplay()at screen init (or useFirebenchDisplayWidget) and report on that handle.
0.1.0-alpha.2 - 2026-06-13 #
Fixed #
- Metrics set on a
startTrace(...)handle (or written while finalizing a screen) before the underlying Firebase trace had started were silently dropped. Metrics and attributes are now buffered and flushed after the trace starts, so none are lost.
Added #
- Nested-navigator support: each
FirebenchNavigatorObservertracks only its own navigator, so a separate observer on a nested navigator no longer clobbers the root observer's active screen. Concurrent screen traces coexist. - Custom per-screen metrics and attributes via
FirebenchDisplay.setMetric/FirebenchDisplay.putAttribute.
Changed #
slow_framesnow explicitly excludes frozen frames (documented).
0.1.0-alpha.1 - 2026-06-12 #
Initial alpha release. Targets the free Firebase Performance backend — no paid SaaS required.
Alpha: the public API may change before the 1.0 release.
Added #
- Drop-in
FirebenchNavigatorObserverthat emits one Firebase trace per screen visit, namedscreen_<RouteName>. - Per-screen metrics:
ttid_ms(time to initial display) and opt-inttfd_ms(time to full display). - Frame metrics per screen:
slow_frames,frozen_frames,total_frames,max_frame_ms, andframes_delay_ms. - Trace attributes:
route,previous_route,display_complete. - Time-to-full-display reporting via
Firebench.instance.currentDisplay()/reportFullyDisplayed()and theFirebenchDisplayWidgetwrapper. - Manual traces:
Firebench.instance.trace(...)andFirebench.instance.startTrace(...)with metric and attribute support. FirebenchConfigfor enabling/disabling tracing, debug-mode tracing, trace prefixing, auto-finish timeout, TTFD and frame tracking toggles, slow/frozen frame thresholds, route ignoring, and custom route-name extraction.- GoRouter support via
GoRouter(observers: [FirebenchNavigatorObserver()]). - Safe by design: all Firebase failures are caught and logged in debug; the SDK never throws into the host app.