Join us live for the third hands-on session of the 4 day Flutter Learning Series - Handling state and data on 26th March 2022 at 7PM sharp.
After the basics and UI creation, get ready for the very important state management of your application.
2. Handling State and Data
Topics we will be Covering
● State
●Stateless vs Stateful Widgets
●Navigation
3. State
The state is information that can read simultaneously when
the widget is built and might change during runtime, in short,
we can say that the State defines the current properties of
the Widget.
According to state, widgets are divided into:
●Stateless widget
●Stateful widget
4. Stateless Widget
● They are static widgets; they are updated only
when initialized.
●It is not dependent on data changes or
behavior changes
●Examples are Text, Icons, or a RaisedButton.
5. Stateful Widget
● They are dynamic in nature.
●It is dependent on changes when user
interacts.
●Examples are Checkbox, Radio Button,
Slider.
6. • Routes- In flutter terminology screen or pages are referred to as
Routes.
• By making use of routes we navigate between pages.
• To navigate between two or more routes we make use of Navigator.
The basic steps now to follow are:
● Create two screens
● Define routes
● Navigate between them using:
● Navigator.pushNamed(): To move to second screen.
● Navigator.pop(): To move to previous screen.
Navigation