maybeOf<T> static method
T?
maybeOf<T>(
- BuildContext context, {
- Object? group,
- bool useNopGroup = true,
- int? position = 0,
Implementation
static T? maybeOf<T>(BuildContext context,
{Object? group, bool useNopGroup = true, int? position = 0}) {
assert(() {
position = position == null ? null : position! + 1;
return true;
}());
return _NopState.getLocal(context, group, position) ??
_getFromRouteOrCurrent<T>(context,
group: group, useNopGroup: useNopGroup, position: position);
}