widget property

  1. @override
T get widget
override

You need to be able access the widget.

Implementation

// if parentState is null then AppStatefulWidget was likely not used.
@override
T get widget => (parentState?.widget ?? super.widget) as T;