-
Notifications
You must be signed in to change notification settings - Fork 3
Dashboard speed optimization by reducing redundant plot function calls #237
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initial review with general comments. I didn't look at the logic in-depth yet and haven't tried running the dashboard myself. I'll plan to do a local build in docker to make sure the production version will work.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All the code changes look good and everything works in docker!
Before I merge this, could you describe in the PR what general changes you made? In the box that says "No description provided."
Because of how reactivity in shiny works, there were many redundant calls.
Every time that we update a reactive variable, it automatically triggers functions that depends on this reactive variable. For example: changing
input$targetVariable
triggerssummaryPlot
, so there is no needIn this PR we removed some of those forced calls of functions that would already be triggered by reactivity.
For example, when changing colours, there is no need to call
summaryPlot
since it will alread be triggered by the change of the reactive variableCOLOR_SEED()
Here is an example of change that was made:
From:
to: