breadboard
breadboard copied to clipboard
Ports and Complexity
So one of the things on my mind is the node / schema / array editing. Because of the flexibility of our types we have a fairly extensive set of switch statements in a form, each of which requires slightly different validation and so forth. And when we hit port-specs or array we then spin up separate "sub forms" for those types (in the form of <bb-schema-editor> and <bb-array-editor> respectively), which then need to report up to the "super form" when their internal values change.
I don't know if there's much we can do overall, because ultimately we support a lot of types and a lot of variation within certain types, but it feels complex in that machinery 🤔
/cc @dglazkov
This needs to be pluggable somehow. I am thinking something like custom port editors/viewers, maybe a PortEditorProvider?
Yeah, I wonder how much of it is down to the fact that we simply have a lot of types to support (and in a nested way at that). Even if we added a configuration with a provider we'd still have a lot of things to support. That said it does feel a little related to #1269 inasmuch as we might want to think through the overall configuration story and journeys.