jsonifyList function

List jsonifyList(
  1. Iterable list
)

Implementation

List<dynamic> jsonifyList(Iterable list) {
  final output = [];
  for (final value in list) {
    if (value is HTStruct) {
      output.add(jsonifyStruct(value));
    } else if (value is Iterable) {
      output.add(jsonifyList(value));
    } else if (isJsonDataType(value)) {
      output.add(value);
    }
  }
  return output;
}