-
-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pattern matching callbacks & ServersideOutput #192
Comments
Hi @jonasvdd, I got it working like this.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, firstly, amazing work with these dash add-ons. 🚀
I'm one of the core developers of plotly-resampler, a library that performs back-end data-aggregation to still retain snappy and interactive plotly figures withholding large amounts of data. At the request of some end-users (predict-idlab/plotly-resampler#91, predict-idlab/plotly-resampler#56, predict-idlab/plotly-resampler#27) I'm looking into the serialization capabilities of our
plotly-resampler
figures for dash apps, so there is no need for a global variable in which we store our figures.As for now I was able to get a minimal working example where I cache the
FigureResampler
, i.e., the plotly-resampler go.Figure thanks to your amazingServerSideOutput
component. See example ⬇️As I want to take the next step towards dynamically creating / removing graphs (e.g., instead of the plot-graph button, we use an add-graph button to render graph on some state fields that the user entered), I would love to also create a working example where we use your ServersideOutput, and this Is where I'm stuck now.
My first try to create such an example would withhold this method (see first method in snippet ⬇️), in which we dynamically create a dcc.Store and the
figure
variable, which we want to (1) store on the server and (2) link to the dynamically created dcc.Store. This would enable to use pattern-matching callbacks for performing graph-updates (see second method in snippet ⬇️).So my question is: How can I use your ServerSideOutput on dynamically created dcc.store objects (via triggering / callbacks or within a method, without using the callback logic itself)? In your documentation, I did not immediately find something on pattern-matching callbacks, which would be highly useful for the more advanced users of your toolkit. I hope this somehow makes sense!
Thanks again for your amazing work! 💪🏼
Cheers, Jonas
The text was updated successfully, but these errors were encountered: