Constructs a new ViewManager instance.
PrivatecurrentThe view currently being processed.
PrivatedirtyArray of views whose state is dirty and needs to be updated.
PrivatelayoutMap of view IDs to views with invalidated layouts.
PrivatelayoutArray of views whose layout is invalid and needs to be recalculated.
PrivatependingViews detached during this tick; drained at end of _tick after state and layout.
PrivatestateView IDs enqueued for state application this batch (dedupes repeated invalidateViewState within a batch).
PrivateviewsSet of views that currently have errors.
Processes all dirty views and views with invalidated layouts, applying state changes and laying out children as needed.
Clears the list of views with errors.
Forces the state of the specified view to be marked dirty, then invalidates it. Use when external state changes require getViews() to run even though the view's own state fields did not mutate.
Registers a control (view) with an error for debugging purposes.
The error object containing debug information.
The view associated with the error. If not provided, uses the current view.
Registers a detached view for deferred cleanup at end of this tick.
Unregisters a control (view) from error tracking.
The view to unregister.
The
ViewManagerclass is responsible for managing the state and layout of views. It keeps track of dirty views and views with invalidated layouts, and processes them during each tick.