I'm trying to display image inside a container with responsive width and height.
Here is my code:
...
child: Column (
mainAxisSize: MainAxisSize.min,
children: [
Row (
children: [
Padding (
padding: EdgeInsets.all(20),
child: Container(
height: MediaQuery.of(context).size.height *.3,
width: MediaQuery.of(context).size.width * 1,
padding: const EdgeInsets.all(15),
decoration: BoxDecoration(
image: DecorationImage(
image: AssetImage("assets/images/gunung.jpg"),
fit: BoxFit.cover,
...
here is the output:
Is there any solutions?
