SlideShare a Scribd company logo
Introduction to Flutter
Developing a simple mobile app
By Wan Muzaffar Wan Hashim
Muzaffar
Founder of MDR-Tech, Co-founder of Anak2U
Worked with mobile industry since 2011
Different industry: M-Commerce, Newsfeed, Media Broadcasting, Food Delivery ,
Airline,Loyalty, Education.
2
Introduction to flutter
Introduction to flutter
Mobile App Development
● A mobile application is a software application designed to run on
smartphones, tablet computers and other mobile devices.
● Users on smartphones typically check the news, weather, email
or their social networks. They have a choice between the mobile
web version or a specially-created mobile app.
5
Mobile App Dev: Current State
Native Development Hybrid Development
● Android
● iOS
● Ionic
● React Native
● Flutter
● Native Script
● Xamarin
Mobile App
Types
● Native
○ Programmed using Swift/Objective C on the iPhone or
using Java/Kotlin on Android devices.
● Hybrid
○ Mix between these two types of mobile applications.
○ Normally based on web programming language, eg: HTML,
CSS, Javascript, Dart
○ Built once to be run on Android and iOS.
● Web Apps / Progressive Web Apps.
○ Web based.
Runs in the phone’s browser.
○ Can have native features based on HTML5
7
What is Flutter
Open source UI Framework by Google
Able to create iOS, Android and web application
using Dart
High performance, high fidelity, low latency, as it
renders the Native UI.
Use DART as main programming language
Open source / github.
About Dart
Dart is a programming language developed by
Google
Learning it isn’t hard if you have experience with
Java or JavaScript. You will quickly get it.
You can use dartpad as an online compiler of Dart
https://dartpad.dev/
Who uses Flutter
https://flutter.dev/showcase
Malaysia Google Trend (over 5 years)
Bridge gap between designer and developer - XD Flutter integration
Bridge gap between designer and developer - Supernova io
Setup your Editor
https://flutter.dev/docs/get-started/editor
You will need to configure an emulator after setting up the SDK.
Online Editor (Demo purposes - no setup)
https://codepen.io/pen/editor/flutter
Everything is a widget
You build widget upon widget.
Your screen, a section in a screen, a tiny little section is
also a Widget.
You create and customize your own widget.
Widget catalog
https://flutter.dev/docs/development/ui/widgets
The boilerplate code of an app - Scaffold
Scaffold(
appBar: AppBar(
title: const Text('Sample Code'),
),
body: Center(child: Text('Hello World')),
floatingActionButton: FloatingActionButton(
onPressed: () => {},
tooltip: 'Increment Counter',
child: const Icon(Icons.add),
),
);
Scaffold
A scaffold is a basic structure of an application having the following property by
default:
● appbar
● body
● floatingActionButton
● bottomNavigationBar
● drawer
Appbar
An app bar consists of a toolbar and
potentially other widgets,
For example, if you would like to add a
button on the left side you use leading and
actions on the right side.
You may change the property
backgroundColor to change the
background color of the AppBar.
Floating Action Button
A floating action button is a circular icon
button that hovers over content to promote
a primary action in the application
floatingActionButton:
FloatingActionButton(
onPressed: () {
// Add your onPressed code
here!
},
child: Icon(Icons.navigation),
backgroundColor:
Colors.green,
Body
This is where you build the content of your application.
Widgets for layouting
We will discover the widgets that are used to position items within a page. Here
are some important/main widgets:
● Container
● Center
● Column
● Row
● SingleChildScrollView
Container
Center(
child: Container(
margin: EdgeInsets.all(10.0),
color: Colors.amber[600],
width: 48.0,
height: 48.0,
padding:EdgeInsets.all(10.0)
),
A container is a box! You can specify the width, height, color, padding and margin.
In the below example, EdgeInsets.all means all direction (top, bottom, left, right)
Center
A widget that centers its child within itself.
Center(child: Text('Hello World')),
Row
A widget that displays its children in a horizontal array.
Row(
children: <Widget>[
Expanded(
child: Text('Deliver features faster', textAlign:
TextAlign.center),
),
Expanded(
child: Text('Craft beautiful UIs', textAlign:
TextAlign.center),
),
Expanded(
child: FittedBox(
fit: BoxFit.contain,
child: const FlutterLogo(),
),
),
],
Column
A widget that displays its children in a vertical
array.
Column(
children: <Widget>[
Text('Deliver features faster'),
Text('Craft beautiful UIs'),
Expanded(
child: FittedBox(
fit: BoxFit.contain,
child: const FlutterLogo(),
),
),
],
)
SingleScrollView
A box which allows a single widget to be scrolled.
You will use this when you have a single box that will normally be
entirely visible, for example a clock face in a time picker, but you need
to make sure it can be scrolled if the container gets too small in one
axis
Visible widget in Flutter
Once you know how to position items on a page, we will see some of the widgets
that you can use in your application. Here are some important/main widgets:
● Text
● Image
● Button
● Icon
● Slider
Text
Text(
'Hello World',
textAlign: TextAlign.center,
style: TextStyle(fontWeight: FontWeight.bold,
color:Colors.red),
),
This widget is used to displays a text with
single style.
You might need to use TextStyle widget as
well with this widget to add styling to the
text, for example to add color, set to bold
Image
Image(
image:
NetworkImage('https://flutter.github.io/assets-for-api
-docs/assets/widgets/owl.jpg'),
)
To show an image. You may show an image
from:
● Downloaded from a URL
● Stored locally in assets folder
Icon
Icon(
Icons.audiotrack,
color: Colors.green,
size: 30.0,
),
As per its name, an icon is a widget that is
predefined, and can be used directly within
your application.
You may refer to Icon documentation, to see
all available icon ready to be used in your
application
https://api.flutter.dev/flutter/material/Icons-class.html
RaisedButton
RaisedButton(
child: Text('Color Changed'),
color: Colors.green,
onPressed: () {
print(“Hello World”)},
),
A raised button, follows Material
design principle is a button that
raises slightly, configurable via
elevation property.
You will need to declare what
should happen when the button is
pressed via it’s onPress property.
Other type of button includes
FlatButton
Slider
Slider(
value: _value.toDouble(),
min: 1.0,
max: 10.0,
onChanged: (double newValue) {
setState(() {
_value = newValue.round();
});
},
A slider can be used to select
from either a continuous or a
discrete set of values.
We will use onChanged property
to update the value of item, once
the value of slider changed.
Stateless Widget
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Container()
}
}
Stateless Widget is a widget that
is immutable.
Stateless widgets cannot change
their state during the runtime of
the app, which means the
widgets cannot be redrawn while
the app is in action.
Stateful Widget
class MyWidget extends StatefulWidget {
@override
_MyWidget createState() => _MyWidget();
}
class _MyWidget extends State<MyWidget>{
@override
Widget build(BuildContext context){
return Container();
}
}
Stateful Widget is a widget that
stores variable (state).
This widget will rebuild itself
whenever there is a change of its
state (variable)
For example when user interact
with a button, you might change
the state/variable within the
widget => Widget will be
refreshed.
Demo - BMI Calculator
Demo
We will create a simple BMI calculator app that will calculate BMI based on height
and weight entered by user.
● An application using stateful widget since we are storing height, weight and
bmi
● Create the structure using scafffold
● Add Scrollview and container
● The container will contain a Column with:
○ Image (logo of our app)
○ App title and subtitle
● Two containers containing slider for user to choose height and weight
● Button when the button is pressed you will do the BMI calculation
BMI Calculator
Full source code can be found here: https://codepen.io/wanmuz86/pen/LYpBGej
Path to learn to build mobile app
● How to create UI element (focus on one page first)
● Navigation, multiple page = Stack, Tab, Drawer
● Passing data from one page to another page
● Retrieving data from Internet
● Storing data in local storage/Shared Preference
● Use device features : Camera, Geolocation, Social Sharing, Photo Library
● Improve architecture
● Finetune - Localization
Create a weather app using API from Open Weather that will show weather based
on Geolocation
Contact me
The Moose Academy
Common Room Bangi
Wan Muzaffar Wan Hashim (LinkedIn)
Notes
During the QnA Session I mistakenly quote price for Apple is 99USD per month, it
is actually 99USD per year.
iOS : 99 USD per year - Need a MAC or Rent macbook on cloud ->
Apple Developer Account
Android - 25 USD per life time -> PC or MAC -> Google Developer
Account

More Related Content

PPTX
Flutter presentation.pptx
PDF
The magic of flutter
PPTX
Flutter Intro
PPTX
PPTX
What and Why Flutter? What is a Widget in Flutter?
PPTX
What is Flutter
PDF
Pune Flutter Presents - Flutter 101
PPTX
Flutter talkshow
Flutter presentation.pptx
The magic of flutter
Flutter Intro
What and Why Flutter? What is a Widget in Flutter?
What is Flutter
Pune Flutter Presents - Flutter 101
Flutter talkshow

What's hot (20)

PPTX
Flutter
PDF
Flutter Tutorial For Beginners | Edureka
PDF
Flutter beyond hello world
PPTX
Flutter workshop
PDF
Getting started with flutter
PDF
Building beautiful apps with Google flutter
PPTX
Flutter introduction
PPTX
Introduction to Flutter
PPTX
Flutter session 01
PPTX
PDF
Flutter state management from zero to hero
PDF
What is flutter and why should i care?
PPTX
Flutter
PPTX
Intro to Flutter SDK
PDF
Introduction to Flutter - truly crossplatform, amazingly fast
PDF
Flutter overview - advantages & disadvantages for business
PDF
Introduction to kotlin
PDF
Flutter for web
PPTX
Introduction to Android and Android Studio
Flutter
Flutter Tutorial For Beginners | Edureka
Flutter beyond hello world
Flutter workshop
Getting started with flutter
Building beautiful apps with Google flutter
Flutter introduction
Introduction to Flutter
Flutter session 01
Flutter state management from zero to hero
What is flutter and why should i care?
Flutter
Intro to Flutter SDK
Introduction to Flutter - truly crossplatform, amazingly fast
Flutter overview - advantages & disadvantages for business
Introduction to kotlin
Flutter for web
Introduction to Android and Android Studio
Ad

Similar to Introduction to flutter (20)

PDF
Basic Introduction Flutter Framework.pdf
PPTX
App Dev-GDG USAR Tech Winter Break 2024.pptx
PDF
Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...
PPTX
Flutter workshop
PDF
A Complete Guide to Building Your First App with Flutter
PDF
Tech winter break - GDG on campus PPT1.pptx.pdf
PDF
Flutter in Action 1st Edition Eric Windmill
PPTX
TechCon Day - 5 App Dev
PPTX
Mobile Applications Development class 03-starting with flutter
PPTX
FlutterArchitecture FlutterArchitecture.ppt
PPTX
FlutterArchitecture FlutterDevelopement (1).pptx
PPTX
Flutter alegria event gdsc pillai college of engineering
PDF
Learn Google Flutter Fast: 65 Example Apps Mark Clow
PPTX
Appplication Development Flutter(2).pptx
PPTX
Lecture 5 _ Building Layouts (1).pptx
PDF
Build beautiful native apps in record time with flutter
PDF
Fluttering
PPTX
Lecture -Introduction to Flutter and Dart.pptx
PPTX
IT_HARIOM_PPjkniugvjnuygr6tf65ed6erd5dT.pptx
PDF
22Flutter.pdf
Basic Introduction Flutter Framework.pdf
App Dev-GDG USAR Tech Winter Break 2024.pptx
Cross Platform Mobile Development using Flutter by Wei Meng Lee at Mobile foc...
Flutter workshop
A Complete Guide to Building Your First App with Flutter
Tech winter break - GDG on campus PPT1.pptx.pdf
Flutter in Action 1st Edition Eric Windmill
TechCon Day - 5 App Dev
Mobile Applications Development class 03-starting with flutter
FlutterArchitecture FlutterArchitecture.ppt
FlutterArchitecture FlutterDevelopement (1).pptx
Flutter alegria event gdsc pillai college of engineering
Learn Google Flutter Fast: 65 Example Apps Mark Clow
Appplication Development Flutter(2).pptx
Lecture 5 _ Building Layouts (1).pptx
Build beautiful native apps in record time with flutter
Fluttering
Lecture -Introduction to Flutter and Dart.pptx
IT_HARIOM_PPjkniugvjnuygr6tf65ed6erd5dT.pptx
22Flutter.pdf
Ad

Recently uploaded (20)

PPTX
Transform Your Business with a Software ERP System
PDF
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
PDF
medical staffing services at VALiNTRY
PPT
JAVA ppt tutorial basics to learn java programming
PPTX
Odoo POS Development Services by CandidRoot Solutions
PDF
AI in Product Development-omnex systems
PPTX
Materi_Pemrograman_Komputer-Looping.pptx
PDF
PTS Company Brochure 2025 (1).pdf.......
PPTX
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
PDF
Upgrade and Innovation Strategies for SAP ERP Customers
PPTX
VVF-Customer-Presentation2025-Ver1.9.pptx
DOCX
The Five Best AI Cover Tools in 2025.docx
PDF
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
PPTX
history of c programming in notes for students .pptx
PPTX
Essential Infomation Tech presentation.pptx
PPT
Introduction Database Management System for Course Database
PDF
Wondershare Filmora 15 Crack With Activation Key [2025
PDF
System and Network Administration Chapter 2
PDF
System and Network Administraation Chapter 3
PDF
How to Migrate SBCGlobal Email to Yahoo Easily
Transform Your Business with a Software ERP System
Claude Code: Everyone is a 10x Developer - A Comprehensive AI-Powered CLI Tool
medical staffing services at VALiNTRY
JAVA ppt tutorial basics to learn java programming
Odoo POS Development Services by CandidRoot Solutions
AI in Product Development-omnex systems
Materi_Pemrograman_Komputer-Looping.pptx
PTS Company Brochure 2025 (1).pdf.......
Agentic AI : A Practical Guide. Undersating, Implementing and Scaling Autono...
Upgrade and Innovation Strategies for SAP ERP Customers
VVF-Customer-Presentation2025-Ver1.9.pptx
The Five Best AI Cover Tools in 2025.docx
T3DD25 TYPO3 Content Blocks - Deep Dive by André Kraus
history of c programming in notes for students .pptx
Essential Infomation Tech presentation.pptx
Introduction Database Management System for Course Database
Wondershare Filmora 15 Crack With Activation Key [2025
System and Network Administration Chapter 2
System and Network Administraation Chapter 3
How to Migrate SBCGlobal Email to Yahoo Easily

Introduction to flutter

  • 1. Introduction to Flutter Developing a simple mobile app By Wan Muzaffar Wan Hashim
  • 2. Muzaffar Founder of MDR-Tech, Co-founder of Anak2U Worked with mobile industry since 2011 Different industry: M-Commerce, Newsfeed, Media Broadcasting, Food Delivery , Airline,Loyalty, Education. 2
  • 5. Mobile App Development ● A mobile application is a software application designed to run on smartphones, tablet computers and other mobile devices. ● Users on smartphones typically check the news, weather, email or their social networks. They have a choice between the mobile web version or a specially-created mobile app. 5
  • 6. Mobile App Dev: Current State Native Development Hybrid Development ● Android ● iOS ● Ionic ● React Native ● Flutter ● Native Script ● Xamarin
  • 7. Mobile App Types ● Native ○ Programmed using Swift/Objective C on the iPhone or using Java/Kotlin on Android devices. ● Hybrid ○ Mix between these two types of mobile applications. ○ Normally based on web programming language, eg: HTML, CSS, Javascript, Dart ○ Built once to be run on Android and iOS. ● Web Apps / Progressive Web Apps. ○ Web based. Runs in the phone’s browser. ○ Can have native features based on HTML5 7
  • 8. What is Flutter Open source UI Framework by Google Able to create iOS, Android and web application using Dart High performance, high fidelity, low latency, as it renders the Native UI. Use DART as main programming language Open source / github.
  • 9. About Dart Dart is a programming language developed by Google Learning it isn’t hard if you have experience with Java or JavaScript. You will quickly get it. You can use dartpad as an online compiler of Dart https://dartpad.dev/
  • 11. Malaysia Google Trend (over 5 years)
  • 12. Bridge gap between designer and developer - XD Flutter integration
  • 13. Bridge gap between designer and developer - Supernova io
  • 14. Setup your Editor https://flutter.dev/docs/get-started/editor You will need to configure an emulator after setting up the SDK.
  • 15. Online Editor (Demo purposes - no setup) https://codepen.io/pen/editor/flutter
  • 16. Everything is a widget You build widget upon widget. Your screen, a section in a screen, a tiny little section is also a Widget. You create and customize your own widget.
  • 18. The boilerplate code of an app - Scaffold Scaffold( appBar: AppBar( title: const Text('Sample Code'), ), body: Center(child: Text('Hello World')), floatingActionButton: FloatingActionButton( onPressed: () => {}, tooltip: 'Increment Counter', child: const Icon(Icons.add), ), );
  • 19. Scaffold A scaffold is a basic structure of an application having the following property by default: ● appbar ● body ● floatingActionButton ● bottomNavigationBar ● drawer
  • 20. Appbar An app bar consists of a toolbar and potentially other widgets, For example, if you would like to add a button on the left side you use leading and actions on the right side. You may change the property backgroundColor to change the background color of the AppBar.
  • 21. Floating Action Button A floating action button is a circular icon button that hovers over content to promote a primary action in the application floatingActionButton: FloatingActionButton( onPressed: () { // Add your onPressed code here! }, child: Icon(Icons.navigation), backgroundColor: Colors.green,
  • 22. Body This is where you build the content of your application.
  • 23. Widgets for layouting We will discover the widgets that are used to position items within a page. Here are some important/main widgets: ● Container ● Center ● Column ● Row ● SingleChildScrollView
  • 24. Container Center( child: Container( margin: EdgeInsets.all(10.0), color: Colors.amber[600], width: 48.0, height: 48.0, padding:EdgeInsets.all(10.0) ), A container is a box! You can specify the width, height, color, padding and margin. In the below example, EdgeInsets.all means all direction (top, bottom, left, right)
  • 25. Center A widget that centers its child within itself. Center(child: Text('Hello World')),
  • 26. Row A widget that displays its children in a horizontal array. Row( children: <Widget>[ Expanded( child: Text('Deliver features faster', textAlign: TextAlign.center), ), Expanded( child: Text('Craft beautiful UIs', textAlign: TextAlign.center), ), Expanded( child: FittedBox( fit: BoxFit.contain, child: const FlutterLogo(), ), ), ],
  • 27. Column A widget that displays its children in a vertical array. Column( children: <Widget>[ Text('Deliver features faster'), Text('Craft beautiful UIs'), Expanded( child: FittedBox( fit: BoxFit.contain, child: const FlutterLogo(), ), ), ], )
  • 28. SingleScrollView A box which allows a single widget to be scrolled. You will use this when you have a single box that will normally be entirely visible, for example a clock face in a time picker, but you need to make sure it can be scrolled if the container gets too small in one axis
  • 29. Visible widget in Flutter Once you know how to position items on a page, we will see some of the widgets that you can use in your application. Here are some important/main widgets: ● Text ● Image ● Button ● Icon ● Slider
  • 30. Text Text( 'Hello World', textAlign: TextAlign.center, style: TextStyle(fontWeight: FontWeight.bold, color:Colors.red), ), This widget is used to displays a text with single style. You might need to use TextStyle widget as well with this widget to add styling to the text, for example to add color, set to bold
  • 31. Image Image( image: NetworkImage('https://flutter.github.io/assets-for-api -docs/assets/widgets/owl.jpg'), ) To show an image. You may show an image from: ● Downloaded from a URL ● Stored locally in assets folder
  • 32. Icon Icon( Icons.audiotrack, color: Colors.green, size: 30.0, ), As per its name, an icon is a widget that is predefined, and can be used directly within your application. You may refer to Icon documentation, to see all available icon ready to be used in your application https://api.flutter.dev/flutter/material/Icons-class.html
  • 33. RaisedButton RaisedButton( child: Text('Color Changed'), color: Colors.green, onPressed: () { print(“Hello World”)}, ), A raised button, follows Material design principle is a button that raises slightly, configurable via elevation property. You will need to declare what should happen when the button is pressed via it’s onPress property. Other type of button includes FlatButton
  • 34. Slider Slider( value: _value.toDouble(), min: 1.0, max: 10.0, onChanged: (double newValue) { setState(() { _value = newValue.round(); }); }, A slider can be used to select from either a continuous or a discrete set of values. We will use onChanged property to update the value of item, once the value of slider changed.
  • 35. Stateless Widget class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { return Container() } } Stateless Widget is a widget that is immutable. Stateless widgets cannot change their state during the runtime of the app, which means the widgets cannot be redrawn while the app is in action.
  • 36. Stateful Widget class MyWidget extends StatefulWidget { @override _MyWidget createState() => _MyWidget(); } class _MyWidget extends State<MyWidget>{ @override Widget build(BuildContext context){ return Container(); } } Stateful Widget is a widget that stores variable (state). This widget will rebuild itself whenever there is a change of its state (variable) For example when user interact with a button, you might change the state/variable within the widget => Widget will be refreshed.
  • 37. Demo - BMI Calculator
  • 38. Demo We will create a simple BMI calculator app that will calculate BMI based on height and weight entered by user. ● An application using stateful widget since we are storing height, weight and bmi ● Create the structure using scafffold ● Add Scrollview and container ● The container will contain a Column with: ○ Image (logo of our app) ○ App title and subtitle ● Two containers containing slider for user to choose height and weight ● Button when the button is pressed you will do the BMI calculation
  • 39. BMI Calculator Full source code can be found here: https://codepen.io/wanmuz86/pen/LYpBGej
  • 40. Path to learn to build mobile app ● How to create UI element (focus on one page first) ● Navigation, multiple page = Stack, Tab, Drawer ● Passing data from one page to another page ● Retrieving data from Internet ● Storing data in local storage/Shared Preference ● Use device features : Camera, Geolocation, Social Sharing, Photo Library ● Improve architecture ● Finetune - Localization Create a weather app using API from Open Weather that will show weather based on Geolocation
  • 41. Contact me The Moose Academy Common Room Bangi Wan Muzaffar Wan Hashim (LinkedIn)
  • 42. Notes During the QnA Session I mistakenly quote price for Apple is 99USD per month, it is actually 99USD per year. iOS : 99 USD per year - Need a MAC or Rent macbook on cloud -> Apple Developer Account Android - 25 USD per life time -> PC or MAC -> Google Developer Account