4 ms·
Take the Container class in Flutter, it can only take a single Widget as a child. Having to write a list of children that is 1 long every time I use a container
by gman83 9y ago
Take the Container class in Flutter, it can only take a single Widget as a child. Having to write a list of children that is 1 long every time I use a container doesn't make sense to me, and to me seems confusing as it will lead to people trying to add more items. I don't know, that's my opinion, maybe I'm wrong :)
- johnfn 9y agoHmm, perhaps it's me not understanding the flutter paradigm, but if something only accepted a single child, I would stop calling it a child and start calling it a more precise name. Like perhaps contents in the case of a container?
- sureshv 9y agoSounds like they took that from Android where IIRC a scrollview could only take one child. Coming from Win32 Android, back in the G1 days, always had its own idiosyncrasies.