flattenHtmlComponents method
Implementation
List<dynamic> flattenHtmlComponents(var htmlComponents) {
var flatHtmlComponents = [];
for (var comp in htmlComponents) {
if (comp["controlType"] == 'PANEL') {
var panelComp = comp;
panelComp["componentList"]
.forEach((element) => flatHtmlComponents.add(element));
} else {
flatHtmlComponents.add(comp);
}
}
return flatHtmlComponents;
}