I want to use a List<Widget> (A list of widgets) I'm very new to flutter and I found this code where I am learning flutter from and apparently this code will not work in flutter in 2021. Can null safety be disabled? or What can I do?
List<Widget> _renderFacts(Location location) {
var result = List<Widget>();
Here's the error I get
The default 'List' Constructor isn't available when null safety is enabled. Try using a list literal[], list.filled or list.generate