Yes! There is a flexbox equivalent. In fact, by default, you’ll almost certainly be using Flex in your Flutter app. Flutter ships with a ton of layout widgets, including Row and Column, which enforce Flex rules on their own. When using those widgets, you can tell their children how to lay out using the properties from justify-content and others that you’re already used to. The following listing shows an example.
// Column widget example body: new Center( child: new Column( 1 mainAxisAlignment: MainAxisAlignment.center, 2 children: <Widget>[ new Text( 'You have pushed the button this many times:', ), new Text( '$_counter', ), ], // ...
The Row widget behaves like the Column widget, but on a horizontal axis. Finally, in addition to Center, you can use the following properties on MainAxisAlignment:
For an in-depth look at Row and Column, read chapter 2.
18.191.233.205