Dart The named parameter 'home' isn't defined
As mentioned in the comments, it seems like you may have modified your Flutter SDK (there was previously a bug in the analysis server that made this easy to do accidentally by running quick-fixes).
There's an open issue about having flutter doctor
detect this here:
https://github.com/flutter/flutter/issues/25220
For now, running the git clean command Günter gave in the comments from inside your Flutter SDK folder should get things back to normal.
Admin
Updated on December 07, 2022Comments
-
Admin over 1 year
when I am trying to run an app in VS code, this message shows up "The named parameter 'home' isn't defined.".
It is a general problem for all flutter projects .flutter doctor says no issues.
I also tried creating a new project from scratch using android studio and Intellij and no progress .it says (theme: and home:) are not identified as named parameters.before that everything was perfectly fine ..please help! :(
-
diegoveloper over 5 yearsmaybe you modified the source code of: MaterialApp
-
Admin over 5 yearsIf true can i restore it back?
-
lena over 5 yearsDo you have several versions of Flutter installed or something?
-
Günter Zöchbauer over 5 years
git clean -xfd
in the Flutter install directory might restore your Flutter installation. -
Ammar Hussein over 3 years@GünterZöchbauer running this command made all required annotations errors
-
Günter Zöchbauer over 3 yearsRun
flutter doctor
that should fix it
-