I am trying out flutter value proposition of multi platforming.
I am on Android Studio.
Hello world works on Android.
Hello world is not launched on Iphone Emulator even though it is shown in the drop down.
I don't see anything to launch the app in a desktop where i can resize the window at will
I don't see anything either to launch the app in the browser.
Any help? Especially for the desktop and web .. The iphone emulator is probably a setting.
I am on Android Studio 3.3.2 and XCode 10.1
Flutter for desktop is in very early stages, as described on the Flutter wiki; it won't work out of the box. If you want to experiment with it, you'll need to manually add desktop support to your project.
Similarly, Flutter for web is a technical preview that requires extra setup to try out.
Related
I'm just starting to program with Flutter and I'm wondering if it's possible to program a whole flutter app, with just vs code, because of many reasons I can't use Android Studio on my laptop.
Just knowing if it's possible would be enough for me :)
Well, I started a standard Flutter App and I'm developing it from the basis.
Yes, you can code a whole Flutter project with VScode, you need just to follow the install process of all requirements for flutter:
https://docs.flutter.dev/get-started/install
However, you will need Android Studio in order to get an Android Emulator, to debug and preview your work process. ( you will not need to run it every time from Android Studio)
and when you will have the emulator installed then you can do the whole code process of a Flutter project only from VScode
Flutter 3.0 is amazing !!
I can make a web app, android & iOS mobile app, and a native Mac app (and more) all from the one code base.
But now my problem is :
How do I specify which OS to build-for and run-on ?
When I do flutter run or debug>run in VSCode it will build-for, and run-on, my Android device first if it plugged in, or else as a Mac app. I want to run it as Web. More generally, I want to specify which OS I want to build and run for.
Both the flutter run command line option, and the VSCode setting (preferably without messing about with launch.json, or else making that seem easy).
You can use
flutter run -d chrome
For running it on chrome
flutter run -d your_device
For mobile device
It depends on the selected device. If you select an Android Device, it will build for Android OS. If you select a browser then it will run the build on your Default Browser and the same goes for other scenarios.
I'm new to flutter, I developed apps in Android Studio for ios devices, and they run perfectly when I run them from Android Studio onto the real device. However, if I try to run the app from the iphone itself (from the launcher icon), the app imediately closes and doesn't run.
Why would this be? Is there anything I can do in the code to enable the app to run from the phone itself, not just through running it in Android Studio?
Thanks for any help!
I am new to Flutter. I want to test my app on an iPhone emulator (or simulator) just to see how does it look in real time?
I am using these:
Windows 10
Visual Studio Code
It is not possible. You need macOS to install Xcode, without which iOS development & running is not possible.
With windows, you cannot even run it on an iPhone if you had one.
I cannot install the Android Emulator in my working environment, therefore I wondered whether it is possible to code/learn Flutter without any mobile device (or emulator). For example, is it possible to run/test the code by using the browser?
There are two non-mobile options, both of which are currently in development stages but could be used for learning Flutter:
flutter-desktop-embedding, particularly the example which you can check out and flutter run with minimal setup, and then modify.
The Flutter for web technical preview.
Flutter Desktop Launcher for Mac OS/Linux, support hot reload via VS Code
GitHub Link: https://github.com/putraxor/flutter_desktop_launcher