We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When I pass the argument it says both are compulsory. Maybe they changed it in flutter SDK I could not find the solution for that.
Help me thanks.
My Custom Widget Class
class ReusableCard extends StatelessWidget { ReusableCard(@required this.colour, this.cardChild); final Widget cardChild; final Color colour; @override Widget build(BuildContext context) { return Container( child: cardChild, margin: EdgeInsets.all(15.0), decoration: BoxDecoration( color: colour, borderRadius: BorderRadius.circular(10), ), ); } }
Here is the implement of the widget
Expanded( child: Row( children: <Widget>[ Expanded( child: ReusableCard(activeCardColor), ), ], ), ),
The text was updated successfully, but these errors were encountered:
@arpit999 better make it this way
ReusableCard({@required this.colour, this.cardChild});
then you can implement it this way
ReusableCard(colour: activeCardColor)
Sorry, something went wrong.
No branches or pull requests
When I pass the argument it says both are compulsory. Maybe they changed it in flutter SDK I could not find the solution for that.
Help me thanks.
My Custom Widget Class
Here is the implement of the widget
The text was updated successfully, but these errors were encountered: