Skip to content

Instantly share code, notes, and snippets.

@ScottS2017
Last active March 15, 2019 12:23
Show Gist options
  • Save ScottS2017/5923855da7077767dec8f5896879837e to your computer and use it in GitHub Desktop.
Save ScottS2017/5923855da7077767dec8f5896879837e to your computer and use it in GitHub Desktop.
No_flexible_Green_Yellow_Containers.dart
import 'package:flutter/material.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
theme: ThemeData.dark(),
home: Scaffold(
appBar: AppBar(
title: Text('Deep Dive Testing'),
backgroundColor: Colors.blue,
),
body: SizedBox(
height: 500.0,
width: 200.0,
child: Container(
child: Column(
mainAxisSize: MainAxisSize.min,
children: <Widget>[
Container(
color: Colors.green,
width: 100.0,
height: 100.0,
),
Container(
color: Colors.yellow,
width: 100.0,
height: 10.0,
),
],
),
),
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment