Fudge
05/25/2019, 6:51 AMTextField. And then I want to make a version of that that validates text input named ValidatedTextField.
I would now need to copy paste the possibly extremely long declaration of TextField , as part of the declaration of ValidatedTextField, and then feed all of these parameters into TextField, and then every time TextField adds new arguments I need to add those to ValidatedTextField.Leland Richardson [G]
05/25/2019, 6:35 PMcurioustechizen
05/27/2019, 6:52 AMTextField? Why is it not possible to use composition here, i.e., "wrap" TextField inside ValidatedTextField? As in, why can we not implement ValidatedTextField in terms of TextField?Fudge
05/27/2019, 8:33 AMfun TextField(text : String, decoration: InputDecoration , keyboardType: TextInputType, textCapitalization : TextCapitalization = TextCapitalization.none, style: TextStyle, textAlign: TextAlign = TextAlign.start, textDirection : TextDirection, autoFocus: Boolean = false, obscureText : Boolean = false, autoCorrect : Boolean = false, blah blah blah blah......................){
// Implementation details
}
How would you now define ValidatedTextField?curioustechizen
05/27/2019, 8:34 AMI would now need to copy paste the possibly extremely long declaration ofI totally misread that. My bad :)TextField
Fudge
05/27/2019, 8:35 AMcurioustechizen
05/27/2019, 8:36 AM