Flutter Could not prepare to run the isolate
please check whether your Flutter Project contains
main.dart
inlib
folder, if not, create it.check your code like this:
import 'package:flutter/material.dart';
import 'package:module_flutter/xxxApp.dart';
void main() => runApp( new xxxApp());
If you are facing the problem even if you have main method in main.dart inside your lib folder
Try
flutter clean
And then
flutter run
Worked for me :)
I had the same error and it happened when I didn't write the main method. so do this
void main() => runApp(MyApp());
MyApp is my main class