Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Flutter for Beginners
  • Table Of Contents Toc
  • Feedback & Rating feedback
Flutter for Beginners

Flutter for Beginners

By : Thomas Bailey, Biessek
4.4 (8)
close
close
Flutter for Beginners

Flutter for Beginners

4.4 (8)
By: Thomas Bailey, Biessek

Overview of this book

There have been many attempts at creating frameworks that are truly cross-platform, but most struggle to create a native-like experience at high performance levels. Flutter achieves this with an elegant design and a wealth of third-party plugins, making it the future of mobile app development. If you are a mobile developer who wants to create rich and expressive native apps with the latest Google Flutter framework, this book is for you. This book will guide you through developing your first app from scratch all the way to production release. Starting with the setup of your development environment, you'll learn about your app's UI design and responding to user input via Flutter widgets, manage app navigation and screen transitions, and create widget animations. You'll then explore the rich set of third party-plugins, including Firebase and Google Maps, and get to grips with testing and debugging. Finally, you'll get up to speed with releasing your app to mobile stores and the web. By the end of this Flutter book, you'll have gained the confidence to create, edit, test, and release a full Flutter app on your own.
Table of Contents (18 chapters)
close
close
1
Section 1: Introduction to Flutter and Dart
6
Section 2: The Flutter User Interface – Everything Is a Widget
10
Section 3: Developing Fully Featured Apps
14
Section 4: Testing and App Release

Functions and methods

As we discussed previously, functions and methods are self-contained chunks of code that work on a specific task. Note that the syntax of methods and functions is identical, so where I refer to functions in this section, I am also referring to methods. Let's look at another example of a function, as follows:

String sayHello() { 
  return "Hello world!";
}

This sayHello function structure is very similar to the main function we explored previously but also includes a return type of String, so the function must have a return statement at the end that returns a value of the expected type. In this example, the function returns a String literal of "Hello world!". If the function could return a String literal or null then, as we saw in the Null safety section, we would mark the function's return type as String?.

Note that the function return type can be omitted because the Dart analyzer can infer the return type from...

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech

Create a Note

Modal Close icon
You need to login to use this feature.
notes
bookmark search playlist download font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Delete Note

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Edit Note

Modal Close icon
Write a note (max 255 characters)
Cancel
Update Note

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY