
Member-only story
Flutter: Creating Tabs in AppBar and associating it with Stateless and Stateful Widgets
Flutter is a mobile App SDK by Google which helps in creating modern mobile apps for iOS and Android using a single(almost) code base.
Unlike other frameworks like React Native, it neither uses JavaScript as a Programming Language nor it needs an interpreter bridge to convert JavaScript code into native code, instead, it compiles directly into Arm binaries and runs on the native platform.
When one opens a Mobile Application, it’s the AppBar
which gets the user first attention and it’s not surprising that app developers would like to provide the most important functionalities of their app within this area.
In Flutter, we can achieve the same by using the
AppBar
ofScaffold
As we know that in Flutter, we can create Material Design using Scaffold which provides AppBar
. The AppBar
also provides a bottom
area which can be used to create TabBar
in the AppBar
.
The TabBar
can contain one or more tabs. Here is how an AppBar
containing a TabBar
with tabs look like
