Repository navigation
feat: Show the component lifecycle state in DevTools - #4245
Merged
spydon merged 4 commits intoDec 1, 2026
Merged
Conversation
Member
|
@ywt-helloworld there are some failing checks on your PR |
Adds a `lifecycleState` helper that reports where a component is in its lifecycle (Removing/Mounted/Loaded/Loading/Detached), following the suggested implementation in flame-engine#4171. The state is included in the `getComponentInfo` service extension response, exposed through the DevTools repository, and shown for the selected component in the component tree section. Each state is covered by a test on the game side. Closes flame-engine#4171
spydon
force-pushed
the
feat/devtools-lifecycle-state-4171
branch
from
December 1, 2026 06:31
d280a9d to
fe883d0
Compare
spydon
approved these changes
Dec 1, 2026
spydon
left a comment
Member
There was a problem hiding this comment.
Extremely sloppy, but fixed up now.
github-merge-queue
Bot
removed this pull request from the merge queue due to a conflict with the base branch
Dec 1, 2026
# Conflicts: # packages/flame/lib/src/devtools/connectors/component_tree_connector.dart
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This adds the component lifecycle state to the DevTools extension, as requested in #4171.
lifecycleState(Component)helper inComponentTreeConnectorthat reports where a component is in its lifecycle:Removing,Mounted,Loaded,Loading, orDetached, following the issue's suggested implementation (checked in that exact order).ext.flame_devtools.getComponentInfoservice extension response.Repository.getComponentLifecycleStatereads it, acomponentLifecycleStateProviderexposes it, and the selected component section shows it asState: <state>. It is refreshed by the existing selected-component poller, so it updates live (e.g. when a component is being removed).Each state is covered by a new test on the game side (
packages/flame/test/devtools/component_tree_connector_test.dart).Closes #4171