Created
August 16, 2020 10:24
-
-
Save stephaniefash/56c8f02bd5ac5cd8231dc3eada8e68e0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class _MyHomePageState extends State<MyHomePage> { | |
String imageSource = | |
'https://images.unsplash.com/photo-1494253109108-2e30c049369b?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=crop&w=1350&q=80'; | |
@override | |
Widget build(BuildContext context) { | |
return new Scaffold( | |
backgroundColor: Colors.white, | |
body: Center( | |
child: Container( | |
decoration: BoxDecoration( | |
border: Border.all( | |
color: Colors.orange, | |
width: 20, | |
), | |
), | |
child: Image.network( | |
imageSource, | |
width: 300, | |
height: 300, | |
fit: BoxFit.cover, | |
), | |
), | |
), | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment