Код: Выделить всё
I/flutter (13782): ══╡ EXCEPTION CAUGHT BY RENDERING LIBRARY ╞═════════════════════════════════════════════════════════
I/flutter (13782): The following assertion was thrown during performResize():
I/flutter (13782): Vertical viewport was given unbounded height.
I/flutter (13782): Viewports expand in the scrolling direction to fill their container. In this case, a vertical
I/flutter (13782): viewport was given an unlimited amount of vertical space in which to expand. This situation
I/flutter (13782): typically happens when a scrollable widget is nested inside another scrollable widget.
I/flutter (13782): If this widget is always nested in a scrollable widget there is no need to use a viewport because
I/flutter (13782): there will always be enough vertical space for the children. In this case, consider using a Column
I/flutter (13782): instead. Otherwise, consider using the "shrinkWrap" property (or a ShrinkWrappingViewport) to size
I/flutter (13782): the height of the viewport to the sum of the heights of its children.
I/flutter (13782):
I/flutter (13782): The relevant error-causing widget was:
I/flutter (13782): ListView (file:///D:/flutterProjects/test_project/test_project/lib/screens/all_obj_screen.dart:19:18)
Если это может помочь, это файл all_obj_screen.dart:
Код: Выделить всё
class AllObjScreen extends StatefulWidget {
@override
_AllObjScreenState createState() => _AllObjScreenState();
}
class _AllObjScreenState extends State {
@override
Widget build(BuildContext context) {
final objects = Provider.of(context);
return Center(
child: Text(
'${objects.items.length}',
style: TextStyle(
color: Colors.white,
fontSize: 25,
),
),
);
}
}
РЕДАКТИРОВАТЬ:
Я пытался запустить приложение как в Visual Studio Code, так и в Android Studio, но проблема та же.
Я также пытался переустановить IDE и флаттер, но безуспешно.
Подробнее здесь: https://stackoverflow.com/questions/593 ... old-errors
Мобильная версия