I would like to bump up the topic of callbacks without outputs again because I discovered this to be a common use-case if you use Dash to communicate with other processes.
One example that comes directly into my mind is if you communicate with a Redis server and want to write some values depending on the user input in the Dash app. In a current case I need to control a process that captures the data. The parameters for the capturing like sample time, buffer size and measurement can be controlled by the user via Dash client. So I find myself creating dummy divs for each parameter for being able to transfer them to the Redis server. I know this is the recommended workaround however I think it is not a nice solution and creates unnecessary complexity in the frontend.
You still need an Output e.g. a dummy div for this to work which is not a nice solution if you want to pass information to the Backend (e.g. Redis server).
I agree on that. It is also cumbersome if you have multiple controls that only do backend operations. You need to create a separate dummy Div for each of these controls. My point is that it would be more convenient to create callbacks without beeing forced to add Outputs.
Nice work. I didnāt know about your extension and I will definetely give it a try I would still like to know why Outputs are enforced by Dash. Is it some limitation of React?
Yes it looks this way. I would like to understand the reason for it though. It does not make much sense to force such workarounds from my point of view.
Well, a key design point of dash is keeping the server stateless. With that ind mind, what you are doing is practically a hack, and I can thus understand why the plotly team didnāt make any efforts to make it pretty.
I get your point. I use Dash to write GUIs for test stations and machines. So it is mandatory for me that it can handle states. I keep asking myself if Dash is the right choice for this kind of task.
I have previously used Dash for this kind of application, and i found it to be a good compromise between flexibility and ease of use. The reason Dash was designed with a stateless server in mind is to enable scaling to many (thousands) of users. You donāt really need that (I assume?), so it that sense it doesnāt matter that you violate this design principle.