開発環境
⭐️Flutter
(flutter_macos_v1.9.1+hotfix.5-stable)
⭐️Android Studio 3.5.1
⭐️Xcode11.2 beata
FlutterのiPhoneシミュレーション起動できない場合、
「flutter doctor」コマンドで調べた。
flutter doctor

Waiting for another flutter command to release the startup lock...
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.9.1+hotfix.5, on Mac OS X 10.14.4 18E226, locale ja-JP)
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[✗] Xcode - develop for iOS and macOS
✗ Xcode installation is incomplete; a full installation is necessary for iOS development.
Download at: https://developer.apple.com/xcode/download/
Or install Xcode via the App Store.
Once installed, run:
sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
✗ CocoaPods not installed.
CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your plugin usage on the Dart side.
Without CocoaPods, plugins will not work on iOS or macOS.
For more info, see https://flutter.dev/platform-plugins
To install:
sudo gem install cocoapods
[✓] Android Studio (version 3.5)
[!] Connected device
! No devices available
! Doctor found issues in 2 categories.
まず、Xcodeの新しいバージョンをダウンロードして、インストールしました。
そして、Xcodeをswitchしました。
sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
次に、cocoapodsのプラグインをインストールする
brew install cocoapods
インストールが終わったら、セットアップする
pod setup
ここで、終わり。
もう一度下記のコマンドで確認しました。
flutter doctor
Xcodeのシミュレータが起動してないので、起動してね。のエラーがでました。
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.9.1+hotfix.5, on Mac OS X 10.14.4 18E226, locale ja-JP)
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 11.2)
[✓] Android Studio (version 3.5)
[!] Connected device
! No devices available
もう一度下記のコマンドで確認しました。
flutter doctor

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, v1.9.1+hotfix.5, on Mac OS X 10.14.4 18E226, locale ja-JP)
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 11.2)
[✓] Android Studio (version 3.5)
[✓] Connected device (1 available)
• No issues found!
これで、成功です!
Runで実行したら、正常に、IOSでFlutterが実行できました。
✨✨Flutter(フラッター)✨✨
— non (@nonnonkapibara) October 22, 2019
Flutterの環境構築と「Hello World」を表示してみたよぉ😍
Flutter(フラッター)は Dart というGoogle が開発している言語🧸🧸
同じコードで 🐸Androidと🍎iOS 両方の📲アプリを作る事ができるフレームワーク😊https://t.co/s7hYorzwhn#Flutter pic.twitter.com/Lxww6AtXd9