context property
BuildContext
context
Implementation
BuildContext get context {
assert(() {
if (_element == null) {
throw StateError(
'This widget has been unmounted, so the State no longer has a context (and should be considered defunct). \n'
'Consider canceling any active work during "dispose" or using the "mounted" getter to determine if the State is still active.');
}
return true;
}());
return _element!;
}