Search packages, repositories and app categories

Package detailsv1.1.0

leak_detector

Used to detect page memory leaks. You can use it to detect whether there is a memory leak in `Widget`, `Element` and `State`.

AndroidiOSmacOS
30-day downloads
61
Likes
65
Pub points
120

Install package

flutter pub add leak_detector

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

LeakDetector is a Flutter/Dart package designed to identify memory leaks in widgets, elements, and states. It helps developers detect when UI components are not being properly disposed of, which can lead to increased memory usage and performance degradation. By integrating it into your app, you can monitor for retained references that prevent garbage collection. The tool is particularly useful during development and testing phases to ensure efficient memory management. It supports Android, iOS, and macOS platforms.

Use cases

  • Identifying widget memory leaks
  • Detecting uncleaned state objects
  • Monitoring element retention
  • Debugging performance issues
  • Testing app stability
  • Validating disposal logic

Key features

  • Real-time leak detection
  • Supports Widget, Element, and State tracking
  • Cross-platform compatibility
  • Simple integration via pub add
  • Developer-friendly output
  • Lightweight runtime impact

Suitable for

  • Flutter developers debugging memory issues
  • Teams focused on app performance
  • Testers validating memory behavior
  • Apps with complex UI state management
  • Developers using StatefulWidget extensively
  • Projects requiring crash-free operation

Considerations

  • Best used in debug mode
  • May impact performance in release builds
  • Requires manual inspection of reports
  • Not intended for production use
  • Limited to detecting retain cycles
  • Needs understanding of Flutter's lifecycle

Categories

Dependencies

Dependency list 3 items

Projects using this package

No data available yet.