of static method
Implementation
static PageModel of(BuildContext context) {
final widget = context
.getElementForInheritedWidgetOfExactType<_SharedModelWidget>()
?.widget as _SharedModelWidget?;
return widget?.model ?? PageModel.fake();
}