frame_insights 0.1.0 copy "frame_insights: ^0.1.0" to clipboard
frame_insights: ^0.1.0 copied to clipboard

In-app frame timing for Flutter: a live FPS HUD, a frame-time chart, and a dashboard that ties each janky frame to the traced work that produced it.

0.1.0 #

Initial release, extracted from the in-app performance monitor of a Flutter demo app.

Core (package:frame_insights/frame_insights.dart)

  • PerformanceMonitor collects engine frame timings and emits reports.
  • PerformanceMonitorStore keeps a rolling window of frames, reports, and jank records, and derives live metrics such as FPS, jank rate, and dropped frame estimates.
  • PerformanceTracer records named regions of work so jank can be attributed to code; PerformanceRebuildCounter counts rebuilds through it.
  • PerformanceRouteObserver labels measurements with the visible route, and ignores the dashboard route by default so opening it does not restart the measurement.
  • PerformanceHealth classifies jank rate and first-frame time against documented thresholds.
  • FrameMetrics, PerformanceReport, and PerformanceJankRecord expose the measurements, each with toJson().

UI (package:frame_insights/ui.dart)

  • PerformanceHud: draggable, collapsible floating window.
  • FrameTimeChart: stacked build/raster/other bars with the over-budget part highlighted.
  • PerformanceDashboardPage and performanceDashboardRoute(): the detail view.
  • PerformanceTheme (a ThemeExtension) carries every colour and PerformanceStrings carries every user-visible string, so the UI follows the app's theme and can be translated. PerformanceStrings.english (default) and PerformanceStrings.chinese ship with the package.
  • PerformanceHudController persists visibility, expansion, and position through an injectable PerformanceHudStorage (shared_preferences by default, InMemoryPerformanceHudStorage for tests).
0
likes
160
points
75
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

In-app frame timing for Flutter: a live FPS HUD, a frame-time chart, and a dashboard that ties each janky frame to the traced work that produced it.

Repository (GitHub)
View/report issues

Topics

#flutter #performance #profiling #debugging #fps

License

BSD-3-Clause (license)

Dependencies

flutter, shared_preferences

More

Packages that depend on frame_insights