I'm trying to follow the guideline to add an image into the splash screen.
The project is built and runs as expected, but the resource in
@mipmap/ic_launcher is red, and Android studio reports
can not resolve symbols.
How can I fix it?
Solution 1: Suragch
When your Flutter project is open in Android Studio, it doesn't seem to respect all of the Android conventions in the
android subfolder of the Flutter project.
As was noted in the comment link, though, you can go to File > Open and open the
android folder. This will recognize it as an Android project and the resource errors should be gone.
That said, you don't need to open it as an Android project. You can just ignore the "errors" and it should work.
Solution 2: CopsOnRoad
You can also go to
Tools > Flutter > Open Android module in Android Studio