Last active
June 21, 2019 18:11
-
-
Save datafoya/eeab49f02be2ca79928458b58391c775 to your computer and use it in GitHub Desktop.
demo2
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
Remember, all three children need to be wrapped in their own Expanded widget. |
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
import 'package:flutter_web/material.dart'; | |
import 'package:flutter_web_test/flutter_web_test.dart'; | |
import 'package:flutter_web_ui/ui.dart' as ui; | |
void main() async { | |
await ui.webOnlyInitializePlatform(); | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Demo2', | |
home: Scaffold( | |
appBar: AppBar( | |
title: Text('Demo2'), | |
), | |
body: Center(child: buildExpandedImages()), | |
), | |
); | |
} | |
Widget buildExpandedImages() => | |
Row( | |
crossAxisAlignment: CrossAxisAlignment.center, | |
children: [ | |
Image.network('https://urlzs.com/NDjgv'), | |
Image.network('https://urlzs.com/69nj6'), | |
Image.network('https://urlzs.com/RsqCz'), | |
], | |
); | |
} |
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
import 'package:flutter_web/material.dart'; | |
import 'package:flutter_web_test/flutter_web_test.dart'; | |
import 'package:flutter_web_ui/ui.dart' as ui; | |
void main() async { | |
await ui.webOnlyInitializePlatform(); | |
runApp(MyApp()); | |
} | |
class MyApp extends StatelessWidget { | |
@override | |
Widget build(BuildContext context) { | |
return MaterialApp( | |
title: 'Demo2', | |
home: Scaffold( | |
appBar: AppBar( | |
title: Text('Demo2'), | |
), | |
body: Center(child: buildExpandedImages()), | |
), | |
); | |
} | |
Widget buildExpandedImages() => | |
Row( | |
crossAxisAlignment: CrossAxisAlignment.center, | |
children: [ | |
Expanded( | |
child: Image.network('https://urlzs.com/NDjgv'), | |
), | |
Expanded( | |
child: Image.network('https://urlzs.com/69nj6'), | |
), | |
Expanded( | |
child: Image.network('https://urlzs.com/RsqCz'), | |
), | |
], | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment