Check out example codes for "No Material widget found. TextField widgets require a Material widget ancestor.". It will help you in understanding the concepts better.

Code Example 1

Widget LoginPage() {
   return new Scaffold(body: *your whole code*)
}

Learn ReactJs, React Native from akashmittal.com