flutter
flutter copied to clipboard
[Bug] explicitly wrap non-list object as list for children property.
When anonymous widget assigns to children property, and it's non list but a single object. It still build as-is.
So,
Stack(
children: Widget()
);
code something like above gets generated.
prevent this by wrapping incomming widget as array - [] for preventing this.
so expected code will be.
Stack(
children: [Widget()]
);