2. Flutter - Widgets and Properties
All widgets must be defined by a property.
All widgets have a list of property that can be changed. Sometimes their value can be regular bool/ints/floats/etc but can also be other widgets (when being containers).
Common properties:
home // property of the app. defines the root widget to show at the start.
body // property of the scaffold widget. used to hold widgets.
child // property used inside another widget to include child widgets
backgroundColor // lets use material design colors.
Common widgets:
AppBar() //
Center() // put child property inside
Text() // shows text
FloatingActionButton(onPressed:(){}, child: WIDGETHERE,)
Colors // colors. CTRL+Q will let use shade of color.
Comments
Post a Comment