maybeOf static method

ServiceScope? maybeOf(
  1. BuildContext context
)

Returns the closest ServiceScope that encloses the given context.

Implementation

static ServiceScope? maybeOf(BuildContext context) {
  return context.dependOnInheritedWidgetOfExactType<ServiceScope>();
}