I know with a ListView
or SingleChildScrollView
RefreshIndicator
just works natively but I want to use a RefreshIndicator
More flexible solution is put your scrollable empty/error state widget into LayoutBuilder
LayoutBuilder(
builder: (context, constraints) => SingleChildScrollView(
physics: AlwaysScrollableScrollPhysics(),
child: SizedBox(
height: constraints.maxHeight,
child: ErrorState(
subtitle: (snapshot.data as ErrorStateful).errorMessage),
),
),
);