Running your first flutter app on Mac

The mobile developer community has hype for Flutter in recent days, Flutter is promising after the Flutter Beta 2 release, its time for mobile developers to give it a try.

Running your first flutter app on Mac

The mobile developer community has hype for Flutter in recent days, Flutter is promising after the Flutter Beta 2 release, its time for mobile developers to give it a try.

Flutter is a natively complied mobile Web, and the Desktop application made by Google. If you are new to flutter development take look at https://flutter.dev

System requirements

  • Operating System: macOS(64-bit)
  • Basics of the command-line tool
  • Disk Space: 700 MB
  • git installed
  • Xcode 9.0 or newer(Mac App Store)
  • Android Studio(Android Studio)

Why Flutter?

Flutter is Google’s UI toolkit for building beautiful, natively compiled applications for mobile, web, and desktop from a single codebase.

Setup Flutter SDK

Download flutter SDK from the git

git clone -b beta https://github.com/flutter/flutter.git

Installing flutter
Installing flutter

Export flutter path

export PATH=$PWD/flutter/bin:$PATH

Export flutter path
Export flutter path

Flutter Doctor

Flutter cli ships with doctor tool and its a super time saver for resolving its dependencies

Flutter Doctor
Flutter Doctor
Warning: The flutter tool uses Google Analytics to anonymously report feature usage statistics and basic crash reports. This data is used to help improve Flutter tools over time.
Flutter tool analytics are not sent on the very first run or for any runs involving flutter config, so you can opt out of analytics before any data is sent by the Flutter tool. To disable reporting, type flutter config --no-analytics, and to display the current setting, type flutter config.

iOS setup

  • Install Xcode 9.0 or newer
  • Install Xcode command line tools sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
iOS setup

Create a simple Flutter app

flutter create hello_world

Create a simple Flutter app
Create a simple Flutter app

Run Flutter app

flutter run

Running flutter app
Running flutter app

Flutter project structure

Flutter project structure
Flutter project structure

What is next?

  1. Dart getting started(https://www.dartlang.org/guides/get-started)
  2. DartPad(https://dartpad.dev)
  3. Dart Packages(https://pub.dev)
  4. Dart SDK API reference(https://api.dart.dev/stable/2.4.1/index.html)

#flutterdev #flutter #available