Most streamed panels are built with a boolean. There is loading and there is done. That works in a prototype where the response is a few hundred bytes and never fails. It breaks the moment a response grows, because between "loading" and "done" there are at least four situations that need different UI and different button behavior.
The first complication is that a structured response arrives in two different senses. The transport can be open while the parser is still deciding whether it has seen a complete value. JSON.parse is all-or-nothing: it needs a balanced document and returns nothing until the closing brace appears, so wiring it to every chunk gives you a panel that stays blank and then pops in whole as this write-up on partial parsers explains. A streaming parser instead models the open positions in the document: strings mid-character, arrays mid-element, objects with unclosed braces per this incremental parser discussion.
The second complication is that the transport can fail after the parser has already produced useful data. If the connection drops mid-object you have a real partial object, and you have to decide whether to show it, discard it, or repair it.
The third complication is silence. A stream that has stopped sending chunks is indistinguishable from a stream that is thinking hard on the next token, unless you measure the gap between chunks yourself.
Four of those situations need retry available and none of them are "loading." That is the case for naming states explicitly.



