I am trying to add a Text widget into CustomScrollView but I got issues like the target is not the same.
This is my widget:
@override
Widget build(BuildContext context) {
final double statusBarHeight = MediaQuery.of(context).padding.top;
return Scaffold(
key: scaffoldKey,
body: CustomScrollView(
semanticChildCount: 2,
slivers: <Widget>[
_buildAppBar(context, statusBarHeight),
Text('test')
],
));
}
The _buildAppBar method returns a SliverAppBar.
I need to use a Padding widget instead of the text, but I think that it will be like the same, that's the same issue.