ScopedWidgetScope constructor

const ScopedWidgetScope({
  1. Key? key,
  2. required Widget child,
  3. required ScopedWidgetBase widget,
})

InheritedWidget for making ScopedWidgetBase retrievable from descendant widgets.

Pass a class inheriting from PageScopedWidget or ScopedWidget to widget.

ScopedWidgetScope.of allows you to retrieve the widget in the ancestor.

ScopedWidgetBaseを子孫ウィジェットから取り出し可能にするためのInheritedWidget

widgetPageScopedWidgetScopedWidgetを継承したクラスを渡します。

ScopedWidgetScope.ofで先祖にあるウィジェットを取り出すことができます。

Implementation

const ScopedWidgetScope({
  super.key,
  required this.child,
  required this.widget,
});