getOptionalComponentNodes method
Implementation
List<CNode> getOptionalComponentNodes(ID id) {
if (isInEditor) {
assert(inEditorPages[id] != null, 'Component with id $id not found');
return inEditorPages[id]?.nodes ?? [];
} else {
final name = appState.forPlayComponentsIDToName[id]!.call();
final res = read<DesignFlowAppCubit>().getComponent(name);
if (res.isRight) {
return res.right.nodes;
}
return [];
}
}