How to import specific Widget to another file
139
I know it, so I use class to return widget to another file like this
class TestWidget extends StatelessWidget
{
final Color bgColor;
final String title;
const TestWidget(Key key,this.title, this.bgColor) : super(key: key);
return (widget here);
}
Author by
Somxhai
Updated on January 03, 2023Comments
-
Somxhai over 1 year
I have created this date picker
Widget completedDatePicker() => Column( children: [ buildDatePicker(), confirmButton(), ]);
and I want to import just this widget to another file like this enter image description here
how do I import it and should I use Stack class to make it like the picture above
-
Somxhai about 2 yearsand how do I import it just the date picker at the bottom of the screen without extra white screen