API Reference / @gtkx/testing / queryController
Function: queryController()
queryController<
T>(widget,controllerType):T|null
Defined in: packages/testing/src/user-event/controller.ts:41
Returns the first controller of the given type attached to a widget.
Type Parameters
T
T extends EventController
Parameters
widget
Accessible
The widget whose controllers are inspected.
controllerType
The controller class to match.
Returns
T | null
The first matching controller, or null when the widget has none.