wrap function

Widget wrap(
  1. Function0<Widget> f

A simple and no headache solution to implement Responsiveness across Tablets and Desktop. It uses the Widely accepted simple fact that you can bascially limit the maxwidth and center the Screen to make it look good on tablets and Desktops. It is used by the library to implement responsiveness for all screens (viz SignIn, SignUp, EmalVerify...)

wrap(() => ScreenToBeMadeResponsive());

PROTIP: To visually see how app looks on different screen sizes see the package device_preview:https://pub.dev/packages/device_preview/


Widget wrap(Function0<Widget> f) {
  return Scaffold(
    body: SafeArea(
      child: SingleChildScrollView(
        child: Center(
            child: Container(
                constraints: BoxConstraints(minWidth: 100, maxWidth: 400),
                child: f())),