How to create Fullstate widget in flutter manually

How to create Fullstate widget in flutter manually

Table of contents

No heading

No headings in the article.

step 1. Create a class with MywidgetName and extends it.

class MyWidget extends StatefulWidget extends {

}

// Then creae a another class with same name but

class MyWidgetState extends State<MyWidget>{
        @override
        Widget build(BuildContext context){
        return Scaffold();
        }
}


// look care fully in seccond class
1. MyWidget comes with MyWidget + State and 
2. After Extending it takes as State<Mywidget> inside the bracks
3. Then it override it and 
4. Build the Widget and Return the Scaffold Widget/ or any widget


// now again go to first class
call this seccond class which we have create 
1. First override your class 
2. Then call the your class with createState Method and return it 

--------------------------

class MyWidget extends StatefulWidget extends {

@override
MyWidgetState createState(){
return MyWidgetState();
}