of static method
Implementation
static ScopeProvider of(BuildContext context) {
final scope = context.dependOnInheritedWidgetOfExactType<ScopeProvider>();
if (scope == null) {
throw ScopeNotFoundException(
'''The scope was not found.The current context does not have a scope.
See the ScopeProvider information to propagate the scope to the widget tree.''');
}
return scope;
}