BuildTracker class

Track rebuilt widgets and build roots for each frame.

You need the TrackingBuildOwnerWidgetsBindingMixin on your WidgetsBinding.

See addIgnored to ignore certain Widgets.

Constructors

BuildTracker({void onBuildFrame(BuildFrame)?, bool printBuildFrame = true, bool printBuildFrameIncludeRebuildDirtyWidget = true, bool printBuildFrameIncludeScheduleBuildFor = true, bool enabled = true})

Properties

enabled bool
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
onBuildFrame ↔ (void Function(BuildFrame)?)
Called after every frame with BuildFrame information collected during the frame build.
getter/setter pair
printBuildFrame bool
Print markdown-formatted stats after every frame.
getter/setter pair
printBuildFrameIncludeRebuildDirtyWidget bool
Print every widget that was built.
getter/setter pair
printBuildFrameIncludeScheduleBuildFor bool
Print every widget for which BuildOwner.scheduleBuildFor was called with stack traces (build roots).
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

addIgnored(List<String> pathStartsWithList) → void
Any Widget path that starts with pathStartsWith will be ignored.
doPrintBuildFrame(BuildFrame frame) → void
Print markdown-formatted stats.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
printTopScheduleBuildForStacks({int count = 10, bool reset = true}) → void
Print markdown-formatted top BuildOwner.scheduleBuildFor stack traces.
resetScheduledBuildForStacksCounts() → void
Reset BuildOwner.scheduleBuildFor stack traces counts.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited