maybeWidget static method
Widget
maybeWidget({
- required WidgetWrapper wrapper,
- required Widget child,
- bool enabled = false,
Conditionally wraps the child
with wrapper
widget if enabled
is true.
Implementation
static Widget maybeWidget(
{required WidgetWrapper wrapper,
required Widget child,
bool enabled = false}) =>
enabled ? wrapper(child) : child;