spotSingleKey<W extends Widget> function

  1. @useResult
  2. @Deprecated('Use spotKey().atMost(1)')
WidgetSelector<W> spotSingleKey<W extends Widget>(
  1. Key key, {
  2. List<WidgetSelector<Widget>> parents = const [],
  3. List<WidgetSelector<Widget>> children = const [],
})

Creates a chainable WidgetSelector that finds a widget with the given key.

Implementation

@useResult
@Deprecated('Use spotKey().atMost(1)')
WidgetSelector<W> spotSingleKey<W extends Widget>(
  Key key, {
  List<WidgetSelector> parents = const [],
  List<WidgetSelector> children = const [],
}) {
  return _global.spotSingleKey<W>(
    key,
    parents: parents,
    children: children,
  );
}