Search code examples
androidreact-nativeandroid-framelayout

Cannot use "FrameLayout", error: "Element FrameLayout must be declared" [Android Studio]


I am doing a small bit of Android development on a React Native project and I cannot work out how to "import" FrameLayout. I'm sure it is very simple but after an hour of Googling I am stumped.

Please see the error below:

Thanks, Al


Solution

  • Possible solutions:

    1) Probably your XML has been corrupted. Try creating a new one.

    2) Have you created it under res/layout path?