var newList = [list1, list2, list3].expand((x) => x).toList()
As of Dart 2 you can now use +:
var newList = list1 + list2 + list3;
As of Dart 2.3 you can use the spread operator:
var newList = [...list1, ...list2, ...list3];
var newList = [list1, list2, list3].expand((x) => x).toList()
As of Dart 2 you can now use +:
var newList = list1 + list2 + list3;
As of Dart 2.3 you can use the spread operator:
var newList = [...list1, ...list2, ...list3];
List<String> _fruits = ["apple", "banana"];
List<String> _vegetables = ["Potato", "carrot"];
_fruits.addAll(_vegetables); //This will join the list
print(_fruits)