Flight Booking

Loading preview

Starting the Flutter app

A showcase of Flutter's flight booking functionality

Get the source

Add it to your project

Copies the Dart source into your app, so you own it. Flutter SDK only, no extra packages.

First time? Run dart pub global activate fluttertemplates_dev, or read the CLI guide.

How it works

_tripType, _passengers and _cabin are the tracked values. Return shows only for Round trip, with Depart filling the row otherwise, but Multi-city adds no legs yet. Cities and dates are plain TextFields without controllers, so there’s no date picker, and Search Flights shows a demo SnackBar. _passengers and _cabin hold the dropdown choices, ready for a search request.

Adapting it

  • Add leg rows for Multi-city.
  • Make the Depart and Return fields readOnly, and call showDateRangePicker on tap.
  • Add Form validation, collecting values into your flight search request.