hcwidget top-level constant
FunctionalWidget
const hcwidget
A decorator for functions to generate a HookConsumerWidget
.
HookConsumerWidget
must be installed as a separate dependency:
dependencies:
hooks_riverpod: any
The name of the generated widget is the name of the decorated function, with an uppercase as first letter.
Implementation
const FunctionalWidget hcwidget = FunctionalWidget(
widgetType: FunctionalWidgetType.hookConsumer,
);