We got another problem. When we type init it does not show initState method in possible match list. In fact it doesn’t show any matching list.
Inside a statefulWidget if we typed the keyword "set" a list of possible match shows up. In the list there was a method named setState((){}) to trigger rebuild to update UI on user interaction.
But recent Chipmunk version of android studio doesn’t show the setState((){}) method in the possible match list. Any idea? [ If duplicate, let us know ]
Question posted in Android Studio
The official documentation can be found here.
The official documentation can be found here.
4
Answers
Try this:
File -> Invalidate Caches / Restart...
Clean your cache of Android Studio
Go to
File -> Invalidate Caches / Restart
See, that error happens quite a few times, and the best way is to remember the syntax.
I’d suggest you complete the syntax yourself and see flutter recognize it.
moreover, you can run
flutter clean
andflutter build
in terminal, and invalidate caches from the files group.Upvote if it helps.
This apparently it is a change in the version of Android Studio (if you are working with Android Studio, by the way, neither setState nor initState nor several other methods work.
My current version of Android Studio is as follows
I did the downgrade and now everything works correctly. I would recommend using the version. Android Studio Arctic Fox (2020.3.1) Patch 2 You can find it in this link
Rolling back to the version of Android Studio Artic Fox, which was the one in which everything worked correctly before, maybe an older and more stable version also solved it too.